Actual Behaviour: Search and Replace: when searching paragraphs $, find previous button brings to the beginning of the document Expected Behaviour Search and Replace: when searching paragraphs $, find previous button should bring to the previous paragraph Reproduce Follow steps in Actual Behaviour
Thank you for reporting the bug. Please attach a sample document, as this makes it easier for us to verify the bug. I have set the bug's status to 'NEEDINFO'. Please change it back to 'UNCONFIRMED' once the requested document is provided. (Please note that the attachment will be public, remove any sensitive information before attaching it. See https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help on how to do so.)
Created attachment 178445 [details] Test case
Reproducible with reporter's sample document and Installation of Version 7.3.0.3 (x64), Build ID 0f246aa12d0eee4a0f7adcefbf7c878fc2238db3 CPU threads: 12; OS: Windows 10.0 Build 19042; UI render: Skia/Raster; VCL: win | Locale: de-DE (de_DE); UI: de-DE | Calc: threaded | ElementaryTheme | My normal User Profile Wrong STR: 1. Open Testcase in Writer 2. Menu ˋEdit → Search and Replaceˊ » Dialog opens 3. As search therm type "laborum.$" 4. Check "Regular Expressions" 5. [Find next] (several times). » As expected "laborum." one by one will be highlighted from top to bottom 6.[Find previous] (several times). » As expected "laborum." one by one will be highlighted from last hit upwards But reproducible with correct STR: 11. Open Testcase in Writer 12. Menu ˋEdit → Search and Replaceˊ » Dialog opens 13. As search therm type "$" 14. Check "Regular Expressions" 15. [Find next] (several times). » As expected free space behind any "laborum." at end of paragraph one by one will be highlighted from top to bottom 16.[Find previous] (several times). Expected: free space behind any "laborum." at end of paragraph one by one will be highlighted from last hit to top of document. Bug: no end of paragraph found until top of document 😥 » search therm "$" color switches to red because no search hit.
No obvious DUP found with query <https://bugs.documentfoundation.org/buglist.cgi?cmdtype=dorem&remaction=run&namedcmd=DUPs147583&sharer_id=19321>
Additional info: a) Already REPRODUCIBLE with Server Installation of Version: 6.0.7.3 (x64) Build-ID dc89aa7a9eabfd848af146d5086077aeed2ae4a5; CPU-Threads: 12; BS: Windows 10.0; UI-Render: GL; Gebietsschema: de-DE (de_DE); Calc: CL, Special devUserProfile b) With Server Installation of Version: 4.0.0.3 WIN10 Build-ID 7545bee9c2a0782548772a21bc84a9dcc583b89; Special devUserProfile That $-search backwards was completely broken.
repro 24.8+
Searching for ".$" is revealing... It works properly in the forward direction (selecting the last character in each paragraph), but for find previous it moves backwards one character at a time (not one paragraph at a time). In other words, in the backwards search, the ending $ seems to just be ignored.
bug 60259 is a great reference. + /* FIXME: this condition does not work for !bSrchForward backward + * search, it probably never did. (pSttNd != &rNdIdx.GetNode()) + * is never true in this case. */
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/8b58007fc5a619012b58a1f8d8731a753bc1c40d tdf#147583 sw find: fix backwards search for emptyPara/endOfPara It will be available in 24.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
I set Verified for the original issue. Issue from comment 7 is a separate one.
Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/e830394c068c229bb840018f2f0e8810da6a1487 related tdf#147583 sw find: fix backwards search for string at end of para It will be available in 24.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.