Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 03-01-2012, 01:06 AM   #1
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
Subgroup Separator

Is there a tweak or option for setting the separator used for subgroups? I've tried looking in the preferences but couldn't find one. I'm now using custom columns in Calibre for creating hierarchical sub-collections for my Sony Reader. However, I don't want to use the default separator ('.') because a lot of the "tags" I'll be using have a period. Would like to be able to use the pipe character ('|') which is the PRS+ default separator for sub-collections.

Thanks!
ilovejedd is offline   Reply With Quote
Old 03-01-2012, 04:32 AM   #2
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Sorry, there is no way to change the subgroup separator short of changing the calibre source code in several places.
chaley is offline   Reply With Quote
Advert
Old 03-01-2012, 02:52 PM   #3
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
Quote:
Originally Posted by chaley View Post
Sorry, there is no way to change the subgroup separator short of changing the calibre source code in several places.
Figured that might be the case.

Anyhow, downloaded the source and tried to make the relevant changes. Got it working (at least it displays correctly in the Tag Browser). Just don't know if I broke anything else in the process. It seems to be working fine...

Anyway, thanks!
ilovejedd is offline   Reply With Quote
Old 03-01-2012, 04:50 PM   #4
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by ilovejedd View Post
Anyhow, downloaded the source and tried to make the relevant changes. Got it working (at least it displays correctly in the Tag Browser). Just don't know if I broke anything else in the process. It seems to be working fine...
IIRC there are places where '.' is checked in library.caches.py, gui2.tag_browser.[model, view, ui].py, util.formatter_functions.py, and gui2.dialogs.tag_categories.py. There could easily be more.
chaley is offline   Reply With Quote
Old 03-01-2012, 06:01 PM   #5
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
I got:
  • library.[caches, database2].py
  • library.server.ajax.py (I reckon this one's useless if I'm not running the content server?)
  • gui2.tag_browser.model.py
  • gui2.dialogs.tag_categories.py
I missed:
  • gui2.tag_browser.[view, ui].py.
  • util.formatter_functions.py

Will go through the ones I missed. Oh well, it displays properly in the tag browser and that's all I really need it to do.

I'm still using the official Calibre builds for library management. The instance running with modified source, I just use with a backup of my library to preview how collections will look like on PRS+, just to check for mistakes, cases (sub-collections in PRS+ is case sensitive), etc. I was getting tires of having to delete and add books to the reader every time I change sub-collections. Unfortunately, I haven't yet tested whether automatic metadata management might be an option (multiple libraries).

Thanks again, for the help!
ilovejedd is offline   Reply With Quote
Advert
Old 03-02-2012, 03:25 AM   #6
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
If you are willing to carry on with this, perhaps we can capitalize on your efforts and incorporate the changes into calibre.

It would need to be a per-library preference (dbprefs) for the character. There is no need at this point to build the GUI to set it. Instead, set the default to something other than period, change all the right places to use the preference instead of the character, and then test it (tag browser display & edit, main gui, content server, searching, template functions, and who-knows what else. ).

Once it is working, we can change the default back to a period and add the GUI to change the preference. The tag browser preferences panel would be a good place. I would be willing to build this part. I already know how & where, and that stuff can be very confusing.

If you create a repository on launchpad, we could exchange source and be sure that we don't lose anything. When done, I would merge the changes into an up-to-date repo and submit to Kovid. Or you could, if you wish.

Do note that Kovid has an unofficial "you touched it last" bug fix policy. He would expect you to fix any bugs related to the changes. This may be more work than you are willing to sign up to do.
chaley is offline   Reply With Quote
Old 03-02-2012, 12:15 PM   #7
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
Quote:
Originally Posted by chaley View Post
If you are willing to carry on with this, perhaps we can capitalize on your efforts and incorporate the changes into calibre.
Looks like this is going to be extremely difficult to implement. Apparently, the '|' character is treated as a separator (same as comma) by Calibre for tag-like columns if manually entering metadata. Not even going to try to touch that one. Composite columns don't seem to be affected. I think I'll just keep to what I'm doing right now - run from source just for previewing sub-collections, normal Calibre for everything else.
ilovejedd is offline   Reply With Quote
Old 03-03-2012, 07:57 AM   #8
Pinecone
Guru
Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.Pinecone ought to be getting tired of karma fortunes by now.
 
Posts: 902
Karma: 1660722
Join Date: Nov 2009
Location: Maryland
Device: PRS-650, PRS-600, PRS-350
How do use Calibre to do hierarchical sub-collections on a Sony with PRS+.

This looks like a great thing with large libraries
Pinecone is offline   Reply With Quote
Old 03-03-2012, 10:55 AM   #9
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
Quote:
Originally Posted by Pinecone View Post
How do use Calibre to do hierarchical sub-collections on a Sony with PRS+.

This looks like a great thing with large libraries
You need to be running PRS+ 2.1 (currently in alpha but quite stable). Once you've installed that, go to Settings » PRS+ Settings » Book Management » Collections and turn on Sub-Collections. You can also specify the Sub-Collections Separator. The '.' period character is compatible with Calibre's sub-groups so that's a good one to use. Unfortunately, several of my tags contain a period so I prefer to use the default '|' pipe character.

Quote:
Collections

Sub-Collections

Allows you to create unlimited extra levels of collections by putting separators in the name.
Here are a few examples based on the default separator (|):
Code:
Name                                    Will become
Genres|Fantasy                          Genres -> Fantasy
Genres|Fantasy|Series|Harry Potter      Genres -> Fantasy -> Series -> Harry Potter
It is recommended to use Calibre to automatically create such collection names from available tags/series/etc (for example, like this).
Sub-Collections Separator

This setting determines which character is used to split sub-collections. The default is the pipe chara

Sub-Collections Separator

This setting determines which character is used to split sub-collections. The default is the pipe character (|).
The other options are: period (.) comma (,) colon (:) semi-colon (;) forward slash (/) tilde (~).
ilovejedd is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Use of comma as field separator and author_sort meme Development 9 04-19-2011 04:26 PM


All times are GMT -4. The time now is 02:26 AM.


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