To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=114976
                 Issue #|114976
                 Summary|Find & replace regular expression behaves strangely
               Component|framework
                 Version|OOo 3.2.1
                Platform|Macintosh
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|code
             Assigned to|tm
             Reported by|juliandroms





------- Additional comments from [email protected] Thu Oct  7 08:10:09 
+0000 2010 -------
OOo 3.2.1 (OOO320m18) has Find & Replace feature that behaves strangely using
regular expression which has been present for more than a year.

I inadvertently thought this was a more over-arching problem, but it appears to
only occur in limited circumstances.

Using Find & Replace in a text document that has more than one paragraph:

(1)  Choose Find & Replace from the Edit menu.
(2)  Select "More options."
(3)  Check the "regular expressions" box.
(4)  Put "$" in the "Search for" box. - $ is reg exp for end of paragraph.
(5)  Put "\t" in the "Replace with" box.  - \t is reg exp for tab.
(6)  Select "Replace all".

Find & Replace will Find correctly the end of each paragraph, but will Replace
the paragraph break with the literal "\t" rather than the tab character that the
reg exp represents.

A workaround is to put ".$" in the "Search for" box and "$\t" in the "Replace
with" box, but this workaround is not particularly obvious.

Another quirk:

(4) Put "^" in the "Search for" box - ^ is reg exp for beginning of paragraph.

When searching for this reg exp alone, it does not identify any paragraph
breaks, whereas when searching for "$" alone does identify paragraph breaks. 
This may be intentional, but if so you may think about changing the
documentation ("list of regular expressions") to reflect the difference in the
two reg exp.

These types of searches are very useful for reformatting data for calc
spreadsheets.  I think it likely that I am not the only one using it for this
purpose.

---------------------------------------------------------------------
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: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to