View Single Post
Old 03-26-2014, 02:57 AM   #7
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
As the others have said, there is no way on the device to remove all the annotations for a book in one go. My practice when doing what you are doing is to remove them as I fix the problem. And in case you don't know, if you press on the highlight in the book, the menu will have a "Delete note" option to remove it.

As to ways to work around this, the annotations are stored in two places. For all books, they are stored in the database table "Bookmarks". For epubs and PDFs on the main memory, they are also in an annotations file.

For purchased kepubs, as Sharkus said, the annotations are synced to the server. I don't think I have ever looked at what happened when I deleted one of these, but my guess would be the annotations would stay on the device until the next sync. Then they would be removed.

For epubs on the SD card, the annotations are only in the database. Deleting the rows from the database will remove the annotations. Doing this doesn't update the tile that shows how many annotations there are for the book. These counts are stored in a way I wouldn't fiddle with. Opening and closing the book will fix them

For epubs on the main memory, it is a bit trickier. With older firmware, if the annotations file exists, the contents will replace the the annotations in the Bookmarks table. With the current firmware, it seems to merge them. A very quick tests seems to show if the annotation is in the table but not in the file, it removes the annotation. If it is in both, it uses whichever has the latest timestamp. The latter is only really used if you change or delete an annotation when opening the annotations list from the home screen.

For epubs on the main memory, I will delete the annotations file as reading them causes some problems. The annotations are fine, but the list doesn't show them in the correct chapters. But, clearing the annotations out of the file would mean the next time the epub is opened, the annotations would be removed. The following is an example of a file with no annotations.

Code:
<annotationSet xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns="http://ns.adobe.com/digitaleditions/annotations">
  <publication>
    <dc:identifier></dc:identifier>
    <dc:title>Summer Knight</dc:title>
    <dc:creator>Jim Butcher</dc:creator>
    <dc:publisher></dc:publisher>
  </publication>
</annotationSet>
If there are annotations, they will be wrapped in "<annotation>" "</annotation>" tags. Removing these will remove the annotation when the book is opened.

The annotations returning after deleting a sideloaded book is because the annotations file is not deleted.
davidfor is offline   Reply With Quote