To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=107194
                 Issue #|107194
                 Summary|Regexp: Search for '\<' pattern breaks replace with '$
                        |n' pattern
               Component|Word processor
                 Version|OOO320m5
                Platform|Unknown
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|editing
             Assigned to|writerneedsconfirm
             Reported by|bormant





------- Additional comments from borm...@openoffice.org Wed Nov 25 09:33:42 
+0000 2009 -------
Regexp search pattern '\<' breaks the replace pattern '$n' on the second and 
more matches in a paragraph.

Tested with: OOo-dev OOO320m5, OOo.3.1.1, OOo.2.4.3
Affected: OOo-dev OOO320m5, OOo.3.1.1, OOo.2.4.3

OS doesn't matter.

How to reproduce:

1) create new text document (Writer)

2) type in 2 paragraphs:
a word b word c word
a word b word c word

3) Ctrl+F
search for: (\<[a-c])[:space:]+
replace with: $1<nbsp>
[ more options vv ]
[x] regular expressions
[Replace All]

4) results

expected: 
a<nbsp>word b<nbsp>word c<nbsp>word
a<nbsp>word b<nbsp>word c<nbsp>word

actual:
a<nbsp>word $1<nbsp>word $1<nbsp>word
a<nbsp>word $1<nbsp>word $1<nbsp>word

We can see that literal '$1' was used on second and subsequent matches in 
paragraph instead of actual matched content of '()' ('b' and 'c').

Result as expected when search for "([a-c])[:space:]+" (without '\<' pattern).

---------------------------------------------------------------------
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-unsubscr...@sw.openoffice.org
For additional commands, e-mail: issues-h...@sw.openoffice.org


---------------------------------------------------------------------
To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org
For additional commands, e-mail: allbugs-h...@openoffice.org

Reply via email to