Hi,
another thing: in Alpha one can save and edit any find/replace (F/R) pattern for later use. I’m using this feature heavily because I’m frequently editing TeX documents converted from Word format where one often has very similar F/R tasks such as formatting citations, references, or bibliographical material. At the same time one cannot do this using some external script because there’s still a wide variance of constructs depending on how the Word author worked.
That all boiling down to: is there a way to save, edit, and reload F/R patterns?
Thanks for all hints!
… with regards from Ladenburg:
-MWL-
On 21 Apr 2011, at 16:44, Martin Wilhelm Leidig wrote:
another thing: in Alpha one can save and edit any find/replace (F/R) pattern for later use. I’m using this feature heavily because I’m frequently editing TeX documents converted from Word format where one often has very similar F/R tasks such as formatting citations, references, or bibliographical material. At the same time one cannot do this using some external script because there’s still a wide variance of constructs depending on how the Word author worked.
That all boiling down to: is there a way to save, edit, and reload F/R patterns?
I would suggest having a look at TM's capability of recording macros. I just recorded a simple search and replace as a macro and used "Save last recording..." to store it in my personal bundle. Now it can be easily called again, e.g. with an assigned keyboard shortcut. After you created the first search macro it is also quite easy to create successive ones, you simply create a copy of the macro in the bundle editor and edit the shown options, which e.g. in my case read:
{ action = replaceAll; findInProjectIgnoreCase = 1; findString = PhD; ignoreCase = 0; replaceAllScope = document; replaceString = Doctor; wrapAround = 1; }
HTH,
Carsten
Am 2011-04-21 um 17:39 schrieb Carsten Hoever:
you simply create a copy of the macro in the bundle editor and edit the shown options
The bundle «editor» won’t let me edit macros, so one has to look up the contents of ~/Library/Application Support/TextMate/Bundles/ and fiddle around with the XML stuff inside one of the bundles found there. And as most of my F/R patterns are prone to be adjusted for the specifics of each and every editing job, maybe just a bit, I’d have to do this frequently.
… with regards from Ladenburg:
-MWL-