[OS X TeX] Search with .* but how to replace?
Herbert Schulz
herbs at wideopenwest.com
Sat Apr 26 13:00:49 EDT 2014
On Apr 26, 2014, at 11:43 AM, Alain Schremmer <schremmer.alain at gmail.com> wrote:
>
> (*) I need to replace \NewTerm{blah} by \textbf{blah}\index{blah} (which is what \NewTerm does) because, occasionally, I need to edit to, say, \textbf{blahs}\index{blah} or \textbf{blahs}\index{blah (to)}.
>
Howdy,
With the default Ruby set as the regex language:
Find: \\NewTerm{(.*)}
Replace: \\texbd{\1}\\index{\1}
Just like \( and \) you've got to quote \, i.e., \\, in the Find section to get the character \.
Good Luck,
Herb Schulz
(herbs at wideopenwest dot com)
More information about the MacOSX-TeX
mailing list