List Info

Thread: Regular Expressions that replace-all can match the result of the replace




Regular Expressions that replace-all can match the result of the replace
user name
2007-11-06 23:23:01
To comment on the following update, log in, then open the
issue:
http://www.openoffice.org/issues/show_bug.cgi?id=82473






------- Additional comments from drkingopenoffice.org Wed Nov  7 05:22:59 +0000 2007
-------
What I actually wrote in the regex HowTo 
http://wiki.services.openoffice.
org/wiki/Documentation/How_Tos/Regular_Expressio
ns_in_Writer was:

"Please be careful when using the Replace All button.
There are a few rare 
occasions when this will give unexpected results. For
example to remove the 
first character of every paragraph you might 'Search for' ^.
and 'Replace with' 
nothing; clicking 'Replace All' now will wipe out *all* your
text, instead of 
just the first character of each paragraph. Issue 82473
discusses this. The 
workaround is to 'Find All', then 'Replace'; perhaps the
safest way is not to 
use the 'Replace All' button at all with regular
expressions."

I'm afraid it does make OOo regex look rather silly...  but
the point of the 
HowTo is to describe what regex actually do - because people
keep re-
discovering all the woes for themselves.

At some point someone will have to bite the bullet and
tackle the Great Regex 
Rethink - if that is likely to be soon then work on the
existing code might be 
wasted - so that must influence any decision to work on this
issue now.




------------------------------------------------------------
---------
Please do not reply to this automatically generated
notification from
Issue Tracker. Please log onto the website and enter your
comments.
http://qa.openoffice.org/issue_handling/
project_issues.html#notification

------------------------------------------------------------
---------
To unsubscribe, e-mail: issues-unsubscribesw.openoffice.org
For additional commands, e-mail: issues-helpsw.openoffice.org


[1]

about | contact  Other archives ( Real Estate discussion Medical topics )