fuxialexander / org-pdftools

A custom org link type for pdf-tools
GNU General Public License v3.0
336 stars 36 forks source link

Use edges as annotation identifier instead of annot-id #87

Open dalanicolai opened 2 years ago

dalanicolai commented 2 years ago

The annot-id is not a stable identifier because the index changes when removing annots with lower indexes. So I would propose to use the page and edges as a unique annot identifier (which is quite straightforward to implement in org-pdftools). I have implemented it in a very quick way, in this commit, however, that gets rid of the annot-id completely, so that it probably is not 100% compatible with org-noter-pdftools.el.

Or is there already some mechanism to keep the annot-id's in sync?

Anyway, you can look at the code for inspiration. I hope you find it a good idea.