LibreOffice Writer won't find search term even though its in the document

I have a document with the word “didn’t” in many places. When I use search, I type “didn’t” and it says no results. If I go to the actual word, copy and paste it in the find box, it magically finds it. But if I type in the EXACT SAME THING it doesn’t. It seems to recognize “didn” until the apostrophe is added. But it’s literally the same word. What is going on?

The apostrophe has been changed by AutoCorrect from a keyboard apostrophe to a “curly” apostrophe. There are two different words there:
Apostrophe

You can stop the change by clicking Tools > AutoCorrect > AutoCorrect Options selecting the tab labelled Localised Options and unticking Replace for apostrophe (and for quotation marks if required).

2 Likes

tdf#149630 - note that likely we now have the opposite problem, after a change for tdf#117643 that treats typographic apostrophe like the straight one.

(You never mentioned which version of LibreOffice you use, nor the specific search options in the Find & Replace dialog like regular expressions.)

1 Like

And to find both options (didn't and didn’t) you can find didn.t (or didn't|didn’t), with [x] Regular Expressions. Beware that it (didn.t) would find whatever value for the . position.

EDIT: to add (or didn't|didn’t) and (didn.t).

1 Like

Use didn['’]t with regular expressions enabled instead.

3 Likes