複雑な align
背景
||'''ほげ'''||'''ふが'''||'''ぴよ'''|| ||foo||bar||baz|| ||abcdefgh||hijklmnopq||rstuvwxyz||
見づらいので整形したい。
やり方
この表をリージョン選択して、
C-u M-x align-regexp
するとミニバッファに以下のようなのが出るので、以下のように答える。
Complex align using regexp: \(||\) Parenthesis group to modify (justify if negative): -1 Amount of spacing (or column if negative): 1 Repeat throughout line? (y or n) y
すると以下のように表が整形される。
||'''ほげ''' ||'''ふが''' ||'''ぴよ''' || ||foo ||bar ||baz || ||abcdefgh ||hijklmnopq ||rstuvwxyz ||