Searching and highlighting a paragraph #1817
-
Discussed in #1815Originally posted by dineshzende July 15, 2022
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
This can have a number of reasons. Then, your PDF need not have the text stored in reading sequence, i.e. in the sequence you are accustomed to read and which also looks like the page is showing it. Third, some PDF creators want to save file size and may simulate special text effects (like boldness or shadowing). You can e.g. simulate bold by writing text twice, the second time with some tiny offset. This will spare the file size of a font's bold version. When you extract (or search) you will encounter e.g. "tthhiiss" or "thisthis" instead of this, and MuPDF will hence not find "this", or find it twice. So if you have a long phrase (presumably for the purpose of later highlighting it), try to search in separate steps: first for the start of the phrase, then for the end. |
Beta Was this translation helpful? Give feedback.
This can have a number of reasons.
First of all, the length of the string you are searching for should not be exaggerated. Three or four lines are probably ok ... if no other problem comes in the way.
Then, your PDF need not have the text stored in reading sequence, i.e. in the sequence you are accustomed to read and which also looks like the page is showing it.
MuPDF search mechanism does not reorder text in any specific sequence before starting to search. Instead it parses text as it physically is stored - and of course will not find something where character sequence is scrambled in some way.
Third, some PDF creators want to save file size and may simulate special text effects (like bo…