Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 03-09-2015, 12:32 AM   #1
darryl
Fanatic
darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.
 
Posts: 585
Karma: 4262968
Join Date: Nov 2011
Location: Australia
Device: Onyx T68 (as of June 2014), Kindle Paperw. Kindle Paperwhite (1st Gen)
Metadata Plugboard Plugin and Kobo

Progress has slightly overtaken this plugin when sending KEPub format to Kobo and re-writing the title. All still works as intended provided that the Kobo extended touch driver is used and epub format rather than KEPub format is sent. The title is then re-written on the device and of course the extended driver does its job and the reader received a kepub file. However, this is not the case when KEPub is sent, either with the extended driver or the Kobo Touch Driver.

As Calibre now supports keeping ebooks in KEPub format ideally the Metadata Plugboard plugin should also support KEPub files. Unfortunately it is most unlikely that my script writing skills are up to the task, so I would like to request that this be placed on the list of future changes. It is not of course urgent as the extended driver does of course accomplish the same task.
darryl is offline   Reply With Quote
Old 03-09-2015, 01:12 AM   #2
darryl
Fanatic
darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.
 
Posts: 585
Karma: 4262968
Join Date: Nov 2011
Location: Australia
Device: Onyx T68 (as of June 2014), Kindle Paperw. Kindle Paperwhite (1st Gen)
Further to my above post I have had a quick look and made a very small dent on my ignorance. It seems that what is probably needed is a modification to at least one calibre binary file, ebook-meta, to support writing KEPub metadata. Looks like a job for Kovid!
darryl is offline   Reply With Quote
Old 03-09-2015, 01:27 AM   #3
eschwartz
Irrational Optimist
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 10,741
Karma: 23029091
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
All the binary exe's are wrappers that load the python source code HERE.

Looking around, the only effort made to support KEPUB is telling calibre in a few key places to treat a KEPUB as an EPUB (for very basic functionality).

As far as send-to-device (and most of calibre) knows, KEPUB is Yet Another Unknown Format.

All that is needed I would guess is to reimplement it as an ebook type plugin that subclasses EPUB, thus making calibre intrinsically aware of KEPUBs.

And once that is done, it can (and should) incorporate the various tweaks and refinements that the current user-installed Output plugin does, etc. -- then calibre will have builtin support for KEPUB.

Last edited by eschwartz; 03-09-2015 at 01:39 AM.
eschwartz is online now   Reply With Quote
Old 03-09-2015, 01:29 AM   #4
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: 6,682
Karma: 6619515
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo: Touch, Glo, Aura H2O
There is very little support for kepubs in the base calibre. The only things I can think of is to allow the viewer to open them and the server to send them with the extension "kepub.epub" to Kobo ereaders. The other support is via an optional plugin.

For the metadata plugboard to work for kepubs, a metadata writer plugin is needed. And ideally a metadata reader plugin to complete the function. It is not hard as it is basically sub-classing the epub code. The only different bit is the cover as that is specified in the OPF using an attribute that isn't used with epub2.

I know I did either the reader or writer sometime in the past, but I haven't released them. Or maybe I posted it in the extended driver thread. I'll try and finish them in the near future. I'll also discuss with Kovid whether they should be integrated into calibre or released as separate plugins. I have a feeling there was something I couldn't see how to do if they were separate, but I can't think of what it was.
davidfor is offline   Reply With Quote
Old 03-09-2015, 01:37 AM   #5
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: 6,682
Karma: 6619515
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo: Touch, Glo, Aura H2O
Quote:
Originally Posted by eschwartz View Post
Looking around, the only effort made to support KEPUB is telling calibre in a few key places to treat a KEPUB as an EPUB -- like the conversion pipeline.
I don't remember seeing that. Unless it was done at the same time as allowing kepubs to be opened by the viewer, which would make sense.
davidfor is offline   Reply With Quote
Old 03-09-2015, 01:42 AM   #6
eschwartz
Irrational Optimist
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 10,741
Karma: 23029091
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
I am guessing based on this: https://github.com/kovidgoyal/calibr...r.py#L706-L707

Probably done for the sake of the viewer, which technically converts a format into an OEB.
I realized that was a slightly awkward description (I am not sure you can actually convert them, also it seems to say "view_kepub" so I am guessing no ) so I quickly reworded it. But you were quicker...

Last edited by eschwartz; 03-09-2015 at 01:44 AM.
eschwartz is online now   Reply With Quote
Old 03-09-2015, 02:06 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: 6,682
Karma: 6619515
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo: Touch, Glo, Aura H2O
Yes, that was what I was thinking of. The commit is https://github.com/kovidgoyal/calibr...4b5f987004ee49. And looking at that, the changes are only used for the viewer.
davidfor is offline   Reply With Quote
Old 03-09-2015, 02:34 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: 26,899
Karma: 5582471
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
That commit is a hack to allow the viewer to view kepub files, without writing a proper input plugin for kepub, since writing an input plugin will mean kepub can also be converted, and as I personally have no use for kepub I dont want to maintain such a plugin. If someone else wishes to commit to maintaining it, I have no objections to adding such a plugin (along with the accompanying metadata reader/writer plugins) to calibre. Or you can just develop and distribute such a set of plugins as standalone plugins.

Generally speaking I like to avoid adding support for single company ebook formats into the calibre core (there are of course exceptions [prominently lrf and the Kindle formats] and this is not a inviolable rule).
kovidgoyal is offline   Reply With Quote
Old 03-09-2015, 03:49 AM   #9
darryl
Fanatic
darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.darryl ought to be getting tired of karma fortunes by now.
 
Posts: 585
Karma: 4262968
Join Date: Nov 2011
Location: Australia
Device: Onyx T68 (as of June 2014), Kindle Paperw. Kindle Paperwhite (1st Gen)
It's a shame my programming skills are not up to par. I imagine that a KEPub handler would simply be a slightly modified epub handler. Probably trivial if you know how. If I get a bit of time in the future I think I might try to learn some Python, but I suspect I would face a bit of a learning curve before I could make this type of modification.

Thank you to those who replied.
darryl is offline   Reply With Quote
Old 03-09-2015, 09:52 AM   #10
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: 6,682
Karma: 6619515
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo: Touch, Glo, Aura H2O
Quote:
Originally Posted by kovidgoyal View Post
That commit is a hack to allow the viewer to view kepub files, without writing a proper input plugin for kepub, since writing an input plugin will mean kepub can also be converted, and as I personally have no use for kepub I dont want to maintain such a plugin. If someone else wishes to commit to maintaining it, I have no objections to adding such a plugin (along with the accompanying metadata reader/writer plugins) to calibre. Or you can just develop and distribute such a set of plugins as standalone plugins.

Generally speaking I like to avoid adding support for single company ebook formats into the calibre core (there are of course exceptions [prominently lrf and the Kindle formats] and this is not a inviolable rule).
I can't say I blame you. I've been putting it off for ages and I might actually use them. I'll have a look at the input plugin and see if I want to do it or not.

In the meantime, for those who want to try it, I've attached the metadata reader and writer plugins. They are quick and dirty and simply sub-class the epub plugins. I haven't added the proper cover handling, but I'll look at later in the week.
Attached Files
File Type: zip KEPUBMetadataReader.zip (668 Bytes, 4 views)
File Type: zip KEPUBMetadataWriter.zip (670 Bytes, 2 views)

Last edited by davidfor; 03-10-2015 at 05:17 AM. Reason: Now with added attachments.
davidfor is offline   Reply With Quote
Old 03-09-2015, 10:45 AM   #11
eschwartz
Irrational Optimist
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 10,741
Karma: 23029091
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
I don't see an attachment...
eschwartz is online now   Reply With Quote
Old 03-09-2015, 09:43 PM   #12
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: 6,682
Karma: 6619515
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo: Touch, Glo, Aura H2O
Quote:
Originally Posted by eschwartz View Post
I don't see an attachment...
Neither do I. I remember selecting them and I'm sure they was listed before I finished the post. I don't have them with me, so I'll have to fix it when I get home tonight.
davidfor is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Metadata Source Plugin] Kobo Books davidfor Plugins 0 01-01-2015 07:02 AM
Metadata Plugboard - I don't get it... _daclaus Library Management 3 08-25-2013 12:13 PM
metadata plugboard not doing anything on kobo touch SonjaD Library Management 2 07-13-2013 11:10 AM
Conflict between plugin, plugboard, and perhaps PRS+ denverh Plugins 2 04-09-2012 10:18 AM
Metadata Plugboard IxiaAurea Calibre 1 11-05-2011 01:13 PM


All times are GMT -4. The time now is 01:51 PM.


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