i18npool: fix spurious regex ^ matching in TextSearch::searchForward()
Thanks to Eike for finding this: The anchors ^ and $ now anchor at the selection boundary because the only text the regex matcher gets passed is the selected text. This in two paragraphs aaa bbb aaa bbb aaa bbb aaa bbb when the selection spans from the second aaa to the third bbb, for "^aaa" finds the second aaa, where previously it found the third aaa at the real paragraph start. This may not be expected by the user, because the behavior of ^ is described as "Match at the beginning of a line" (or paragraph in our case), which the previous implementation did. (regression from 806ced87) Unfortunately it's not obvious how to implement the same in searchBackward(). Change-Id: I07f7a8476b672d9511fa74ca473c32eea427698f
Showing
Please
register
or
sign in
to comment