Issue 91608 - RegEx: Text found with "Find" not Replaced when using "&" or "$0"
Summary: RegEx: Text found with "Find" not Replaced when using "&" or "$0"
Status: CLOSED OBSOLETE
Alias: None
Product: Writer
Classification: Application
Component: editing (show other issues)
Version: OOo 2.4.0
Hardware: PC All
: P4 Trivial (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2008-07-12 23:49 UTC by abdulmumit
Modified: 2017-05-20 10:11 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description abdulmumit 2008-07-12 23:49:01 UTC
Text found with "find and replace" is overwritten by "Replace with" string 
despite using a regular expression sign "&" or "$0" in the "Replace with" 
string. Heavily injures usefulness of regular expressions and find & replace.

Example:
We seek a text (regular expression): "\<[:alpha:]?\ "
We want it to be replaced with: "&xyz"
We find something matching the regexp: "a "
After replacing we should get: "a xyz"
But instead we get: "&xyz"

This works a bit randomly, i.e. it rarely happens that the "&" sign does it's 
job, but then stops again.

Tested with:
OOo 2.4.0 Writer, Kubuntu 8.04
openoffice.ux.pl 2.4.0 Writer, Windows Vista Home Premium 64 bit
OOo Portable 2.4.0 Writer, Windows Vista Home Premium 64 bit
OOo 2.4.1 Writer, Windows Vista Home Premium 64 bit

On the same machine openoffice.ux.pl 2.1 Writer seems to be free of the bug.

Issue 36405 (http://www.openoffice.org/issues/show_bug.cgi?id=36405) concerns a 
very similar (or identical) defect, but it's very old (version 1.1.2).
Comment 1 michael.ruess 2008-07-14 07:35:36 UTC
Reassigned to SBA.
Comment 2 stefan.baltzer 2008-07-15 11:25:39 UTC
Adjusted summary and added keyword "regression".
Reassigned to AMA.
Comment 3 hanya 2015-10-25 03:22:31 UTC
This problem can not be reproduced on AOO 4.1.1.