I just "discovered" a use for a Calibre feature today ("Manage User Categories) to allow me to build various "lists" such as favourite authors etc, all very cool!
However I think the feature could be improved if you did not have to always go into the manage dialog to add to a user category. When you have a large database it is a bit painful to scroll up/down the list to find an author etc, plus it as not as convenient as a right-click on your library view could be.
So I started playing with the source code and have a very simple working implementation with the user category hard-coded (i.e. works for me, if no-one else cares/wants it then no problem). However I could submit the changes as a patch if it was developed a bit further.
There are various ways the context menu could be structured. From a user perspective I think the simplest to use (least clicks) would be for the user category name to appear as a sub-menu a bit like this:
Add to user category ==>
User Category 1 ==>
User Category 2 ==>
However that would seem to require that every time a context menu is built to get the user category names via either
(1.1) interrogate the database, or
(1.2) interrogate a cache, or
(1.3) interrogate a tweak option value
Option (1.1) is likely undesired for performance reasons, and option (1.3) might be considered too complex for users and prone to becoming out of date as users add/remove categories in the tag viewer. I would need some guidance to implement option (1.2) and also the issue with caches is of course knowing all the places they need to be refreshed.
The alternative approach is to force the user through a popup dialog. Personally I hate popups where they can be avoided, but I can accept that in this situation if the above is unacceptable/undesired then it seems the only alternative. So the menu could look like this:
Add to user category ==>
The dialog that appears could be one of two implementations I can think of:
(2.1) A simple popup list where the user chooses a category to add to (like remove format dialog), or
(2.2) Re-use the existing Manage User categories dialog
I would prefer option (2.1) here as a user I think though more work to code it. Option (2.2) would be possible by butchering the existing code a bit. For instance when the dialog is in this 'mode' rather than displaying "all" authors/tags/publishers etc on the LHS you restrict it to just data from the selected row(s). However the user would still need to first select the category, then select all the values on the LHS and the button to add them to your category. Lots more clicks, and more clicks suck imho.
Anyone have any thoughts on this? Would love to see the feature or really not bothered? Guidance would be appreciated if someone would like to see it as a patch, or else it will just stay forever in my local copy of Calibre...