|
|
Thread Tools | Search this Thread |
12-04-2022, 05:47 PM | #1 |
Junior Member
Posts: 3
Karma: 10
Join Date: Dec 2022
Device: Kindle Paperwhite
|
opening ebook-viewer at the offsets that Kindle uses for exported annotations
Hello,
Is there a way to pass the offsets that Kindle uses for exported annotations as a CLI parameter to ebook-viewer, so that it opens at a given annotation? I use Kindle Paperwhite + Calibre as a tool to upload books in azw3 format. I just leant that the annotations I make, while using Kindle, are stored in a separate file with azw3r extension and can be extracted from it. I successfully used 2 methods: The annotations are in a format Code:
OFFSET_START OFFSET_END Note: 'annotation text' Code:
309905 309906 Note: 'my annotation' 565577 565581 Note: 'my second annotation' I'm not sure what exactly the offset represents. Maybe it could be converted to epubcfi somehow? Maybe there's another notation of the open-at argument that I should use. I would like to store the notes outside of Kindle or Calibre and use deep-linking to the Calibre viewer. Thank you in advance |
12-04-2022, 10:00 PM | #2 |
creator of calibre
Posts: 43,853
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, there's no pre-existing code to convert offsets in amazon's formats to something more standard. The offsets refer to byte offsets in the internal binary representation of those formats.
|
Advert | |
|
12-05-2022, 12:39 PM | #3 |
Junior Member
Posts: 3
Karma: 10
Join Date: Dec 2022
Device: Kindle Paperwhite
|
Thank you for the quick answer
Since ebook-viewer can read and render azw3, maybe there is a code there that I could re-use to at least extract the highlighted text between the binary offsets? (I'm a developer) Are you aware of any other library that knows how to use those binary offsets? This way I could use --open-at search:"EXTRACTED_SELECTED_TEXT" I know it's not perfect but as long as the selected text is unique enough it would do the job. |
12-05-2022, 01:24 PM | #4 |
Grand Sorcerer
Posts: 6,496
Karma: 84420419
Join Date: Nov 2011
Location: Tampa Bay, Florida
Device: Kindles
|
You might want to check out these threads:
azw3r highlight and note extraction info KRDS - A parser for Kindle reader data store files |
12-05-2022, 01:45 PM | #5 |
Well trained by Cats
Posts: 29,799
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Slightly
I would love a plugin that seeks the location of the annotations. I use them on my reader to note errors. Being able to use GoTo Location in the Editor would be wonderful. (And not just for Kindles. A whole series for the different devices. After all, what is the best way to PROOF? On the target device) |
Advert | |
|
12-06-2022, 09:28 PM | #6 | |
Junior Member
Posts: 3
Karma: 10
Join Date: Dec 2022
Device: Kindle Paperwhite
|
Quote:
Reading through those threads helped me realize that azw3r tool has -r option, which should give me the original text. I tested it briefly. It didn't work for me yet but maybe I'm doing sth wrong. Then I discovered the tool you wrote: KRDS. It worked like a charm. I followed your explanation to combine it with kindleunpack and this gave me the results I needed. The only remaining step in my project would have been filtering out formatting tags. Some of my annotations highlighted the text that had additional formatting. At the end of the day, in one of the comments in the thread, I came across somebody recommending Kindle Mate. This software works for me out of the box, so I won't have to add any scripting for now. Otherwise I would build it on top of KRDS. You guys did a fantastic job. Thanks again |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
eBook viewer not opening in Ubuntu 20 | martinf | Devices | 5 | 03-01-2023 10:02 AM |
Calibre ebook viewer not opening | Inman | Viewer | 16 | 06-15-2022 10:29 PM |
Problem opening ebook viewer | MJLee | Viewer | 5 | 10-06-2020 07:02 AM |
Annotations in Calibre Ebook Viewer | jstash | Calibre | 1 | 05-22-2020 02:24 AM |
Aura Annotations exported to the PC? | Beniamina | Kobo Reader | 6 | 09-16-2017 10:22 AM |