https://bugs.documentfoundation.org/show_bug.cgi?id=149793
Bug ID: 149793
Summary: Undo search & replaced regex $ fails and causes major
subsequent undo/redo problems
Product: LibreOffice
Version: 7.3.4.2 release
Hardware: x86-64 (AMD64)
OS: Windows (All)
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Writer
Assignee: [email protected]
Reporter: [email protected]
Description:
If one searches for the regex $ and replaces it, undo only undoes the
replacement but does not replace the end-of-paragraph marker, resulting in
further broken undo/redo behavior that ultimately causes !!br0ken!! to appear
multiples times.
Steps to Reproduce:
1. Open a new document. Turn on View | Formatting Marks just to make sure you
can see what's happening clearly. (This doesn't affect the bug, it happens with
this option on or off.)
2. Type the letter A followed by a hard return, the letter B followed by a hard
return, and C. If you turned on formatting marks, you should see A, B, and C
followed by an end-of-paragraph (EOP) mark.
3. Open Find and Replace. Put $ in the search box. Put a space (or anything) in
the replace box. Make sure "Regular Expressions" is checked under "other
options." Hit Replace All. ABC should now appear on one line, followed by a
single EOP mark.
4. Now hit undo. Whatever you replaced $ with is gone, but ABC is still on one
line, followed by an EOP mark, and two EOP marks have returned below that line.
The cursor is after the A.
5. Now hit undo again. Cursor goes to the beginning of the third line, as if
the letter C had been erased.
6. Now hit undo again. Cursor jumps up as if B had just been erased. The EOP
mark on the third line is gone. EOP mark on the second line is still there.
7. Now hit undo again. Nothing happens.
8. Now hit undo again. EOP mark on the second line disappears, cursor jumps
after the A.
9. Now hit undo again. A disappears. BC and EOP mark still on first line.
10. Undo is unavailable. Now hit redo. A returns.
11. Hit redo. EOP mark appears after A, BC followed by EOP mark goes to next
line.
12. Hit redo. !!br0ken!! appears before BC followed by EOP mark.
13. Hit redo. An EOP mark is inserted, moving "!br0ken!!BC" to the next line.
14. Hit redo. !!br0ken!! appears.
15. Hit redo again. The EOP markers are removed and replaced by whatever you
replaced the EOP markers with in your first search-and-replace.
16. This sequence can be repeated ad infinitum.
Actual Results:
As described above.
Expected Results:
The actual results of the replace of the EOP makers should be undone.
Reproducible: Always
User Profile Reset: No
Additional Info:
Version: 7.3.4.2 (x64) / LibreOffice Community
Build ID: 728fec16bd5f605073805c3c9e7c4212a0120dc5
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI render:
Skia/Raster; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL
--
You are receiving this mail because:
You are the assignee for the bug.