04-15-2014, 05:26 AM | #646 |
Guru
Posts: 657
Karma: 64171
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300, Kobo Aura HD, iPad (Marvin)
|
Cheers for that, Rev. Bob.
One question for you regarding the modify changes, are you also going to modify the quality check PI to test for the kobo stuff / empty spans ? |
04-15-2014, 07:11 AM | #647 |
Wizard
Posts: 1,760
Karma: 9918418
Join Date: Feb 2013
Location: Here on the perimeter, there are no stars
Device: Kobo H2O, iPad mini 3, Kindle Touch
|
|
Advert | |
|
04-23-2014, 03:20 PM | #648 | |
Wizard
Posts: 1,760
Karma: 9918418
Join Date: Feb 2013
Location: Here on the perimeter, there are no stars
Device: Kobo H2O, iPad mini 3, Kindle Touch
|
Quote:
Meanwhile, I have been reminded to add one more type of "garbage" element to the cleanup list, and it comes in this form: <?dp n="3" folio="" ?> (Where N can be any number.) This seems to be an artifact of some creation software that I haven't encountered directly, but it doesn't appear to serve any purpose in a finished ebook - so out it comes! It's not even as useful as an attribute-less SPAN element, which could at least theoretically be targeted by CSS. Therefore, the strip-spans module now removes anything of this form: <\?dp([^>]*?)\?>\n? (Or, for those who don't speak regex, "any single tag delimited by <?dp at one end and ?> at the other, containing anything except the > character in between, along with an optional linefeed at the end." ) The attached versions of the plugin include that fix, and I've updated the help file to remove the "experimental" notes and document the self-closing and empty-removal features. If there are no objections to this version, the only thing I see that's left to do is choose between the one-routine and two-routine options. As before, the file with the longest name is the two-routine version. Feedback is encouraged, but please let me know which version of the code (one or two routines) you're using. |
|
04-23-2014, 03:37 PM | #649 |
Grand Sorcerer
Posts: 6,366
Karma: 12117217
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
|
I'll give it a try (two routines), because I use the previous version quite a lot with no problem at all.
|
04-24-2014, 01:15 PM | #650 |
Guru
Posts: 657
Karma: 64171
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300, Kobo Aura HD, iPad (Marvin)
|
Going to give the 2 routine version a try.
I personally think that's the one to finalise, as some user may want to keep the kobo stuff, but strip the empty spans. With regard to the '<\?dp([^>]*?)\?>\n?' - should you include the \n? - as there may be instances where that \n could be between two words, which in the html would then render as a space, so removing it would be wrong. Unless you can guarantee that it's removable in which case never mind. |
Advert | |
|
04-24-2014, 06:57 PM | #651 | |
Wizard
Posts: 1,760
Karma: 9918418
Join Date: Feb 2013
Location: Here on the perimeter, there are no stars
Device: Kobo H2O, iPad mini 3, Kindle Touch
|
Quote:
|
|
04-25-2014, 05:09 AM | #652 | |
Guru
Posts: 657
Karma: 64171
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300, Kobo Aura HD, iPad (Marvin)
|
Quote:
Never seen that element before, so can't illuminate you, I would have thought though that it would cause validity problems. |
|
04-25-2014, 05:30 AM | #653 |
Wizard
Posts: 1,760
Karma: 9918418
Join Date: Feb 2013
Location: Here on the perimeter, there are no stars
Device: Kobo H2O, iPad mini 3, Kindle Touch
|
XML uses the <?foo?> syntax for processing instructions, but I don't know of any - besides the top-of-file XML declaration itself - that are legal in EPUB content.
|
05-06-2014, 07:58 PM | #654 |
Junior Member
Posts: 1
Karma: 10
Join Date: May 2014
Device: kindle 5, nook simple touch
|
Hi. I have tried to found the same plugin for Mobi format, but looks like it doesn't exist. Can you add support of mobi format to this plugin?
|
05-06-2014, 08:53 PM | #655 |
Ex-Helpdesk Junkie
Posts: 19,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
No, the internal structure of MOBI does not allow for editing.
calibre has a builtin tool called Polish Book, which has fewer extended options than this, but does support AZW3 (mobi8). |
05-12-2014, 07:51 AM | #656 |
Junior Member
Posts: 7
Karma: 10
Join Date: Aug 2011
Device: oyo
|
Hi, i've just realised, that plugin isn't updating Publisher field. Is it right? Or is it some settings i got wrong? I have ticked "Update metadata", but Publisher remains unchanged.
|
05-12-2014, 08:05 AM | #657 | |
null operator (he/him)
Posts: 20,954
Karma: 27620688
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Quote:
Works for me - my test is Show Metadata in calibre book viewer ctrl/i Can't think of any setting that would cause it not to work BR |
|
05-12-2014, 02:18 PM | #658 |
Junior Member
Posts: 7
Karma: 10
Join Date: Aug 2011
Device: oyo
|
Well, It looks like I put it a bit wrong. Changing publisher from aaa to bbb works, but, I usually just remove publisher information. It's usually inconsistent and in my opinion misleading. So, that is what I do: I erase this field from metadata, and then update epub with plugin. Publisher remains the same.
|
05-12-2014, 05:31 PM | #659 | |
null operator (he/him)
Posts: 20,954
Karma: 27620688
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Quote:
BR |
|
05-12-2014, 10:51 PM | #660 |
Ex-Helpdesk Junkie
Posts: 19,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Same with tags -- I had a plugboard to clear them since I only use them for library functions like tracking error/edit status, original source, etc.
Didn't work until I recently switched to filtering and allowing "anthology" and other such new tags through. I don't think calibre updates fields to empty, since that could mean wiping data accidentally -- although some people control their db metadata well enough that it would be intentional. |
Tags |
modify epub |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] Quality Check | kiwidude | Plugins | 1198 | 10-05-2024 01:14 AM |
[GUI Plugin] Manage Series | kiwidude | Plugins | 167 | 07-28-2024 03:07 PM |
[GUI Plugin] Open With | kiwidude | Plugins | 403 | 04-01-2024 08:39 AM |
Modify ePub plugin dev thread | kiwidude | Development | 346 | 09-02-2013 05:14 PM |
[GUI Plugin] Plugin Updater **Deprecated** | kiwidude | Plugins | 159 | 06-19-2011 12:27 PM |