Showing results for 
Show  only  | Search instead for 
Did you mean: 

Find highlight off in pdf reader

Making moves

here's an illustration:



This one: 5.3 Full training pipeline? Were you searching for "pretrain"? On mine, the misalignment is much less dramatic, maybe the width of 1/3-1/2 character:


The built-in PDF viewer creates each page as a background image on an HTML canvas. A transparent layer of text is positioned in front of the image to support Find in page, highlighting, and text selection. If you use the Page Inspector in the Developer Tools to give the text some color, you can see glitches in how it lines up. Here, the text layer runs a little narrow on the line with the highlight, while it runs a little wide on the next line.


I assume this is caused by the viewer not using the identical font face and font size for the background image and text layer, but I haven't dived into it deeply.

Mozilla uses the PDF.js JavaScript library for this viewer, which is developed on the following Github site where an issue like this usually would be submitted: