Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 08-30-2018, 07:44 PM   #256
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
Quote:
Originally Posted by JimmXinu View Post
New Test Version

Here's a first cut version with 'always include' checkboxes.
After you finish fine tuning this plugin are you planning to add access to customize the plugin from the menu as you do with EpubMerge? It would be consistent with most other plugins, vice having to go strictly through calibre - preferences.
DoctorOhh is offline   Reply With Quote
Old 08-30-2018, 08:13 PM   #257
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,328
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
Quote:
Originally Posted by DoctorOhh View Post
After you finish fine tuning this plugin are you planning to add access to customize the plugin from the menu as you do with EpubMerge? It would be consistent with most other plugins, vice having to go strictly through calibre - preferences.
I wasn't really planning on it. EpubMerge has a menu because it has more than one top-level function. EpubSplit doesn't and having a menu with only two options, Do the Thing and Configure, seems odd to me. But I'll think about it.

What do people think of having a Config button on the EpubSplit dialog instead of a menu?
JimmXinu is offline   Reply With Quote
Advert
Old 08-31-2018, 01:13 AM   #258
sweth
Connoisseur
sweth began at the beginning.
 
Posts: 67
Karma: 10
Join Date: May 2015
Device: Kobo Aura H20, Kindle Fire 7 (7G), Kindle PW (2G), Nook GlowLight Plus
Quote:
Originally Posted by JimmXinu View Post
Exactly.

BTW, I use tooltips a lot for further info:
Attachment 165900
Ah, I never noticed those. Thanks! I went to go test this just now, though, using the latest version of the plugin you just posted (and am going to test the "per TOC" etc changes next!), but for some reason, the drop-down only shows 5 custom columns, none of which is the subseries column that I want to use. Is that limit intentional?
sweth is offline   Reply With Quote
Old 08-31-2018, 01:50 AM   #259
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,328
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
@sweth - Depends what kind of column it is. Currently, only columns of internal types 'text' or 'comments' are offered. AKA 'Text' and 'Long Text'.

A 'Text Series' type column (internal 'series') could be supported, but the series number would always be 1 setting it from EpubSplit as it stands now.

I'd have to add code to remember how many books had been split, notice the Source column is a 'series' type and then set it with the value. And even then, the numbers would be order you split them, which could be different than order in the source epub.

But I'll look into it.
JimmXinu is offline   Reply With Quote
Old 08-31-2018, 02:01 AM   #260
sweth
Connoisseur
sweth began at the beginning.
 
Posts: 67
Karma: 10
Join Date: May 2015
Device: Kobo Aura H20, Kindle Fire 7 (7G), Kindle PW (2G), Nook GlowLight Plus
Quote:
Originally Posted by JimmXinu View Post
New Test Version

Here's a first cut version with 'always include' checkboxes.

Functionally, I think it works:
  • 'Always include' checkboxes on each section are, when checked, added to new book(s) in addition to selected sections.
  • Default title for new book(s) is still take from first selected section, even if earlier sections are checked for 'always include'.
I can confirm that both of the above seem to work fine, as does as the "per TOC" behavior.

Quote:
Issues:
  • UI is kinda crap.
    • How's a novice user supposed to know when to check boxes and when to select?
    • Should 'always include' checkboxes be configurably hidden until option is enabled?
    • Needs tooltips if nothing else.
  • I don't think I'm de-duping if a section is both checked and selected.
Without radically changing the layout of the UI, I think just hiding the checkboxes until enabled in config might be simplest. Hiding that by default would also minimize the chance that the lack of de-dupe would be needed, I think, since that would probably only come into play if someone was confused about the check vs select thing and tried to do both for the same single section?
sweth is offline   Reply With Quote
Advert
Old 08-31-2018, 02:04 AM   #261
sweth
Connoisseur
sweth began at the beginning.
 
Posts: 67
Karma: 10
Join Date: May 2015
Device: Kobo Aura H20, Kindle Fire 7 (7G), Kindle PW (2G), Nook GlowLight Plus
Quote:
Originally Posted by JimmXinu View Post
@sweth - Depends what kind of column it is. Currently, only columns of internal types 'text' or 'comments' are offered. AKA 'Text' and 'Long Text'.

A 'Text Series' type column (internal 'series') could be supported, but the series number would always be 1 setting it from EpubSplit as it stands now.

I'd have to add code to remember how many books had been split, notice the Source column is a 'series' type and then set it with the value. And even then, the numbers would be order you split them, which could be different than order in the source epub.

But I'll look into it.
When the built-in Series is selected as a field to copy after split, though, the index *does* get set to whatever the next autoincremented value is. I thought custom series columns were the same as that Series column under the hood?
sweth is offline   Reply With Quote
Old 08-31-2018, 02:27 AM   #262
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
Quote:
Originally Posted by JimmXinu View Post
What do people think of having a Config button on the EpubSplit dialog instead of a menu?
That would be great, if not the customize plugin feature under preferences will do fine.
DoctorOhh is offline   Reply With Quote
Old 08-31-2018, 03:37 AM   #263
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,233
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by JimmXinu View Post
What do people think of having a Config button on the EpubSplit dialog instead of a menu?
It's OK for me as they don't change a lot (I think this is the first time I've gone to preferences after the initial setting).
Terisa de morgan is offline   Reply With Quote
Old 08-31-2018, 02:44 PM   #264
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,328
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
New Test Version

Okay, I think this version has all of the changes discussed in the last few days (except multi-level TOC, which is just more complexity than I want to deal with in EpubSplit right now.)
  • Change New Book per Section code to include non-TOC sections with previous TOC.
  • Add (configurably enable-able) 'Always Include' feature.
  • Add 'Configure' button to dialog.
  • Allow 'series' custom columns for Source Col and set series num to number of book split by simple count.
  • Move Source Column to top of config dialog for better visibility.

Quote:
Originally Posted by sweth View Post
When the built-in Series is selected as a field to copy after split, though, the index *does* get set to whatever the next autoincremented value is. I thought custom series columns were the same as that Series column under the hood?
I can tell you from empirical testing that custom series columns don't auto-increment when set from in EpubSplit. And de-duping sections/checked was trivial, I just forgot to do it.

Quote:
Originally Posted by davidfor View Post
You could rebuild the TOC. That will work for a lot of books. And it is one of the thing I do in my FFF post-processing plugin.
Back up a second! You made a plugin to post-process after my plugin? What on earth are you doing???

Last edited by JimmXinu; 09-02-2018 at 02:49 PM. Reason: Remove obsolete test versions
JimmXinu is offline   Reply With Quote
Old 08-31-2018, 11:12 PM   #265
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,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by JimmXinu View Post
Back up a second! You made a plugin to post-process after my plugin? What on earth are you doing???
It was actually written for another source of epubs. There were some things in how they built them that I didn't like. Originally, it was simply to replace the stylesheet. For that, I initially modified the Modify ePub plugin to do this, but then decided to add other things that I was doing for all of these books. This includes smartening the punctuation, tweak some things about the ToC and rebuild it, run count pages and adding them to the appropriate reading lists.

When I started using FFF, I just extended it. The stylesheet was one as I didn't want to add it to the FFF config and maintain it in two places. That isn't as much of a worry since it can now be loaded from a file. One of the things I do is to split the title into a separate page. The above source uses a text title page that has the title and author. This shows nicely in various places on my Kobo ereaders. The first page that FFF produces looks messy as a cover, so I split the title and author to a separate page. And then fiddle with the layout of the titlepage tags (replace the br's with paragraphs and add a class).

And for the record, the code I use to rebuild the ToC is:
Code:
    def _rebuild_toc(self, container):
        from calibre.ebooks.oeb.polish.toc import from_xpaths, commit_toc
        self.log('\t\t\t_rebuild_toc')
        header_xpath = ['//h:h%d'%i for i in xrange(1, 4)]
        self.log('\t\t\t\theader_xpath: {0}'.format(header_xpath))
        new_toc = from_xpaths(container, header_xpath)
        if len(new_toc) == 0:
            self.log('\t\t\t\tToC not built')
            return False
        self.log('\t\t\t\tEntries added to ToC: %d' % len(new_toc))
        self.log('\t\t\t\tToC: {0}'.format(new_toc))
        commit_toc(container, new_toc)
        return True
That of assumes the headings are used for chapter titles. For EpubSplit, it would probably be better to use the ToC build from a conversion. I haven't looked at doing that, but, from memory, the Modify ePub does this for a few of its functions, so it should be possible.
davidfor is offline   Reply With Quote
Old 09-01-2018, 01:03 AM   #266
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,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
@JimmXinu: After writing the above, and looking at the Modify ePub plugin, I thought of an alternative for the multi-level ToC.

At the moment, you are building a new ToC from the files that are copied to the new book. An alternative is to copy the NCX as well and then remove the entries for the files/links not copied. This would keep the hierarchy. Another advantage is if there are ToC entries pointing to places inside the files, these will be maintained as well.
davidfor is offline   Reply With Quote
Old 09-01-2018, 05:45 AM   #267
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,233
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by JimmXinu View Post
New Test Version
  • Allow 'series' custom columns for Source Col and set series num to number of book split by simple count.
Just a comment, why is not happening the same for the standard series? I mean, for the standard series the number is copied "as is", but not modified.
Terisa de morgan is offline   Reply With Quote
Old 09-01-2018, 10:20 AM   #268
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,328
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
@davidfor - That's an idea worth looking into, at least.

@Terisa de morgan - Source Column is for saving where did this new split book come from. By default, it's populated with "{title} by {author}" (using source book title). When using a series type column, I figure it's more useful to know "this was the 1st, 2nd, etc book split from that book".
JimmXinu is offline   Reply With Quote
Old 09-02-2018, 01:36 AM   #269
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,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
@JimmXinu: I tried the latest beta yesterday, and it is much better when making multiple books in a single session. Being able to set the common files is very good.

Having said that, I find the check boxes a little clumsy. I have to select each individually. The simplest would be a button at the bottom to "Mark selected as Always Include". Alternatively, add a right-click menu to do this.

Using the right-click menu would be a way to do multiple books. Change the column to a test with the list of books a file is to be put in. Then menu items would be "All" and the names of the new books. Plus an "Add to new book..." that would prompt for a name. Though that could be a button at the bottom of the dialog.
davidfor is offline   Reply With Quote
Old 09-02-2018, 02:48 PM   #270
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,328
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
New Test Version
  • Change New Book per Section code to include non-TOC sections with previous TOC.
  • Add (configurably enable-able) 'Always Include' feature.
  • Add 'Configure' button to dialog.
  • Allow 'series' custom columns for Source Col and set series num to number of book split by simple count.
  • Move Source Column to top of config dialog for better visibility.
  • Add context menu(right-click) check/uncheck feature.

Last edited by JimmXinu; 09-04-2018 at 03:46 PM. Reason: Remove obsolete test versions
JimmXinu is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] EpubMerge JimmXinu Plugins 522 04-01-2024 10:25 AM
[GUI Plugin] Open With kiwidude Plugins 403 04-01-2024 08:39 AM
[GUI Plugin] KindleUnpack - The Plugin DiapDealer Plugins 492 10-25-2022 08:13 AM
[GUI Plugin] FanFictionDownLoader JimmXinu Plugins 3985 05-08-2015 11:18 PM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 12:27 PM


All times are GMT -4. The time now is 01:35 AM.


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