cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
erisch
New member
Status: New idea

I currently read a lot of pdfs with many references to previous formulas, definitions and graphs. These references are useful to look back where the formulas or definitions came from and what they looked like. However, if there is a lot of jumping around in the document, it gets very confusing to always scroll back to where you clicked the reference.

My request is a feature where hovering over a reference in a pdf pops up a small window with a preview of what you would see when clicking the pdf-internal link.

Something similar to visual studio code's peek definition when working with code or on gitter and github when hovering the mouse over an issue.

Another easier idea would be a "return" button, like "drawboard pdf" has, where you can jump to a state from before klicking the reference. However I think the peek functionality is far superior and I couldn't find any pdf reader, that implements this.

3 Comments
jscher2000
Leader

That's an interesting idea. The built-in PDF viewer is based on an open source project developed at https://github.com/mozilla/pdf.js.

Some time ago, there was a discussion of how this might work and the request was closed. There were some later comments with more thoughts, one of which looks very detailed. I think it's worth a review to see whether anything here could be useful in raising the idea again: https://github.com/mozilla/pdf.js/issues/5835.

Regarding the navigation problem, you generally can use the Back button or equivalent keypress (on Windows, Alt+Left Arrow) or right-click > Left Arrow to go back to the location where you clicked an internal link/bookmark in a PDF. Dedicated buttons would be nicer, and presumably could hook into the same basic mechanism.

steel835
Familiar face

Btw, you can click 'Back' after clicking the reference to scroll back to the position where you were. Though it can stop working if the pdf viewer is embedded into the page.

erisch
New member

Thanks for your Comments! Didn't realise I could just go back, this alone helps 🙂

And also thank you for linking me to the closed issue, The last comment  on the page was super useful. He points to a Github repo where someone actually implemented a solution where there is a preview when you hover over a internal link. Just create a bookmark with the url as some javascript and you can activate and deactivate. Makes me wonder why nothing like this is actually part of PDF.js

Also the preview is always below the cursor, so there is a lot more polishing possible.