ミームの死骸を待ちながら

We are built as gene machines and cultured as meme machines, but we have the power to turn against our creators. We, alone on earth, can rebel against the tyranny of the selfish replicators. - Richard Dawkins "Selfish Gene"

We are built as gene machines and cultured as meme machines, but we have the power to turn against our creators.
We, alone on earth, can rebel against the tyranny of the selfish replicators.
- Richard Dawkins "Selfish Gene"

研究室でRubyが役立つときそのいち

rtfファイルでゼミ資料を書いている時、
「図2-3」
をキャプションと本文からすべて検索して
「図2-4」
にしたい。以降の図2-4、図2-5もどうように置き換えたい。


JeditXでは正規表現の検索はできるが、それを保存して数値に変換してプラス1,という処理はできないっぽい。久々にRubyの出番かもしれない…と思って少しコード書いてみたら、だいぶ忘れてた。


ところで

FireFoxで使用フォントを平成明朝と平成角ゴシック(いずれも研究室の標準フォント)にしたら、日本語の入力がことごとく化けて焦った。