Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Development

Notices

Reply
 
Thread Tools Search this Thread
Old 10-22-2023, 05:16 PM   #1
bengalih
Junior Member
bengalih began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Oct 2023
Device: smartphone
Annotations under the hood

Hello. New(ish) user first time poster.

I would like to understand how annotations are working a bit better under the hood.

1) When logged into Calibre thick client using the "Annotations Browser" it appears that you can see annotations added by any user. However deleting a user does not delete their annotations. Additionally, (re)creating a user with the same name doesn't link the old annotations to the new user.

I'm sure that the latter is intentional (or expected) - since likely each user has a unique ID in the database that isn't re-linked just because name is the same.
I'm wondering if not deleting annotations for a user when user is deleted is also by design? I can see arguments either way.

However, since it does not do this, I'm wondering if there is a way (or one would be considered) to be able to search all annotations by user name to delete or else add an option to library maintenance to delete all annotations by users who don't exist?

2) I would like to know how exactly annotations are tagged to a book and how they move around?
For instance, it looks like you can copy a book to another library and the annotations are moved with it. However if you save the book to disk and then manually add it, the annotations are not retained.

3) In general, are annotations still in active development to add more features like those I mention that will help preserving them short of the standard text export option?

I assume (like almost every ereader) there is no standard used for annotations, if there is please let me know what I can look up in addition to the questions above.

Thanks!
bengalih is offline   Reply With Quote
Old 10-22-2023, 11:13 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,565
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
1) I dont recall not deleting them was intentional or not, but given how annotations are stored, it's not likely to change. Annotations are actually stored in three places, the database, the config folder and inside epub files (unless you disable the latter in the viewer prefs)

2) As long as you save and re-import epub it should work assuming again you haven't disabled saving annotations in file. And if you are using annotations in both the local viewer and content server, you will need to enable the viewer to view annotations form either a specific or all users in the viewer preferences.
kovidgoyal is offline   Reply With Quote
Old 10-23-2023, 02:21 AM   #3
bengalih
Junior Member
bengalih began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Oct 2023
Device: smartphone
Quote:
Originally Posted by kovidgoyal View Post
1) I dont recall not deleting them was intentional or not, but given how annotations are stored, it's not likely to change. Annotations are actually stored in three places, the database, the config folder and inside epub files (unless you disable the latter in the viewer prefs)

2) As long as you save and re-import epub it should work assuming again you haven't disabled saving annotations in file. And if you are using annotations in both the local viewer and content server, you will need to enable the viewer to view annotations form either a specific or all users in the viewer preferences.
Thanks. So for #2 first (I will circle back to #1 in a later post). Maybe I am doing something wrong, or there is a problem with my setup (or maybe I'm misunderstanding you), but I can't seem to recreate all of this:
  • If I move a book to another library (and choose to delete on move), then annotations are copied to the new library.
  • However if I save the book to disk and then re-add it after deleting it from the library then all annotations are gone.
    I have not disabled saving annotations to the epub. The setting "Keep a copy of annotations/bookmarks in the e-book file" under Viewer prefs > Misc is still checked (default).

Also, could you please provide clarification/guidance on "you will need to enable the viewer to view annotations form either a specific or all users in the viewer preferences"?

Indeed I am trying to use annotations in both local viewer and content server. I see no ability to view annotations from all users in either one, at least not in-context.

Specifically, you can only see the annotations for the user you are currently logged in as using Content Server. I see no way to view another user's annotations.

In the Viewer, it appears you have to go into preferences and put in a particular username under Misc settings to see that user's notations. While you could go in and change this for each user it seems rather cumbersome. For one, simply having to manually change it. Secondly, not (easily) knowing which users might have added notations . Third, not being able to see all annotations from all users at once.

I realize that the viewer has the option to "Browse Annotations" on a specific book. This does provide a list of all notations, but it is a bit hard to navigate this list and more problematic (at least for my wish list) is that it doesn't allow you to see these annotations in context of the book. This is the issue with many programs who simply provide an "export" feature - it provides a list, but doesn't let you see the highlights/annotations in context.

As every user (with the possible exception of sometimes me) will be using Context Server to view the books remotely, my primary desire is to allow all users to see annotations from other users (at the very least, of course granular views would be nice, but I am not asking for that now).
Is this possible and I am overlooking it?

Thanks.
bengalih is offline   Reply With Quote
Old 10-23-2023, 03:25 AM   #4
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,565
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
If the save to disk route is not working then thats likely a bug of some kind, opena bug report for it.

And no there is no concept of viewing all users annotations in the content server, as i sad in your other thread that would be a privacy violation. Please follwup in that thread
kovidgoyal is offline   Reply With Quote
Old 02-14-2024, 06:37 PM   #5
pjeby
.
pjeby began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Apr 2013
Device: Various
On a related note, is there a way to edit the user ID of annotations, or merge duplicates? I've somehow managed to end up with three copies of some annotations under my own user ID, "Local E-book viewer user", and "Anonymous Content Server User". I have the server configured to require logins, and the desktop reader configured to use my user ID, but it seems like duplicates are being generated when I use the desktop reader. In fact, just opening a book in the desktop reader generates duplicates of the annotations that were previously done via the content server.
pjeby is offline   Reply With Quote
Old 02-14-2024, 11:06 PM   #6
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,565
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Yes, they will be duplicated. The desktop readers *syncs* its annotations with those of a content server user, they dont use the same actual annotations store.
kovidgoyal is offline   Reply With Quote
Old 02-16-2024, 04:24 AM   #7
pjeby
.
pjeby began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Apr 2013
Device: Various
So there's no way to migrate "anonymous content server user" to a specific user, then, except by modifying the database directly?
pjeby is offline   Reply With Quote
Old 02-16-2024, 04:33 AM   #8
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,565
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Not sure what you are asking. annotations are stored in the database, making any change to them requires modifying the database.
kovidgoyal is offline   Reply With Quote
Old 02-23-2024, 02:33 AM   #9
pjeby
.
pjeby began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Apr 2013
Device: Various
I meant some way through the UI to effect the change -- i.e. to merge users' annotations or change the user assigned to an annotation.

I often find that Calibre has a way to do what I want but sometimes the UI is in a place I would never have found on my own. So I thought this might be one of those cases, and wanted to ask before trying to hack on the db directly.
pjeby is offline   Reply With Quote
Old 02-24-2024, 08:11 AM   #10
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,565
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No there's no UI for moving annotations between users or merging annotations.
kovidgoyal is offline   Reply With Quote
Reply

Tags
annotations


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Large images on Kindle... what goes on under the hood? Oxford-eBooks Amazon Kindle 3 11-29-2022 09:50 PM
Annotations: Capture/Convert Kobo-Kindle (uses OpenWith and Annotations Plugins) EnergyLens Related Tools 12 03-28-2020 02:04 PM
Seriously thoughtful tragedy at Ft. Hood for those who have not heard kindlekitten Lounge 7 11-06-2009 01:02 PM
McSpadden, J. Walker: Robin Hood v1.0 2007-10-18 JSWolf Kindle Books (offline) 0 10-18-2007 05:04 AM
McSpadden, J. Walker: Robin Hood v1.0 2007-10-18 JSWolf BBeB/LRF Books (offline) 0 10-18-2007 05:03 AM


All times are GMT -4. The time now is 05:59 PM.


MobileRead.com is a privately owned, operated and funded community.