[OS X TeX] Warning - Find broken in TexShop 1.35b, no undo

Bob Kerstetter bkerstetter at mac.com
Thu Sep 2 13:56:39 EDT 2004

Hi Ralph,

On Sep 2, 2004, at 10:12 AM, Ralph Martin wrote:

> I hope this is not another false alarm.
> However, with regular expressions OFF, I did a search for
> ( )
> and replace all with
> ()
> I got quite undesired results, with all ( replaced by () and all ) 
> replaced by ().
> Worse still, there is no undo for find and replace.
> I have just messed up my lecture notes for next semester quite 
> badly... :-(

I assume you're using TeXShop 1.35.   When you are using Regex Find, 
there is an option in the "More Options" pane called "Delimit by 
Whitespace". When this is checked the Find searches for each word 
separately. So if you search for:

blah whatever

the search will find "blah" and "whatever" but not "blah whatever". 
This is the same thing as searching for blah|whatever using regex. This 
"Delimit by Whitespace" option works for the various search syntaxes 
(ruby, perl....) and for "Simple Matching" (regex off)

In your case, if you had "Delimit by Whitespace" enabled and regex off, 
it would find "(" and replace it with "()" and ")" and replace it with 
"()". So result would be "() ()" --- kind of a bummer.

The regex panel is pretty cool. Very flexible. And a very sharp knife. 
I did something similar to this on day one.

Undo does work, but you have to switch to the text window to activate 
it. This is different from the regular system-wide Find.

Take care,


--------------------- Info ---------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
           & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Post: <mailto:MacOSX-TeX at email.esm.psu.edu>

More information about the MacOSX-TeX mailing list