<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - REPLACE not working if there is a footnote or endnote anchor at end of paragraph"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=137737#c20">Comment # 20</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - REPLACE not working if there is a footnote or endnote anchor at end of paragraph"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=137737">bug 137737</a>
from <span class="vcard"><a class="email" href="mailto:mikekaganski@hotmail.com" title="Mike Kaganski <mikekaganski@hotmail.com>"> <span class="fn">Mike Kaganski</span></a>
</span></b>
<pre>My proposal now is:
1. Fix this by excluding special processing of footnote/endnote anchor. This
will change the behavior: the footnote anchor will be considered a "character"
(non-word, so e.g. regex g\b will find "following" in the first body
paragraph). Note: "$ will *not* find the first body paragraph's last " anymore,
while "[:control:]$ will (but of course, one would need to use captures or
look-ahead assertions to not replace the footnote/endnote character itself,
also removing the note itself).
2. In the long run, see how to process the rest of the special characters
consistently. Namely, they are RES_TXTATR_FLYCNT (fly anchor), RES_TXTATR_FIELD
(field), RES_TXTATR_REFMARK (reference), RES_TXTATR_TOXMARK (index entry),
RES_TXTATR_META and RES_TXTATR_METAFIELD (no idea when these are used). The
problem here is that each of them will create the same problem; and for those
that conceptually can't be considered "control characters", we need to drop
them from the string at *all* times, not only when they are at start/end of
string, and also when they are outside of the nStart/rEnd boundaries.
Please reply what you think specifically about #1 here. Note again, that this
would fix it in a very different way compared to what OP wanted.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>