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 04-02-2025, 02:35 AM   #931
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 45,321
Karma: 168808723
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Please note the last sentence of what I wrote. It's entirely possible that those artifacts have survived Amazon's conversion to KFX and then back to ePub. If you think those are rather stupid, you should take a look at many commercially generate ePubs and their stylesheets—many of which I believe were generated by interns who had never created an ebook before. OTOH, as I have argued several times, how many people who are not professional or serious amateur ebook creators would ever look at the contents of a stylesheet or .opf file?
DNSB is offline   Reply With Quote
Old 04-02-2025, 08:19 AM   #932
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Quote:
Originally Posted by Jaws View Post
I'm encountering three different kinds "unit inconsistencies" in KFX --> ePub; they may be unrelated, they may be due to KFX itself, to the KFX Input plugin, or something in Calibre's own conversion process. Or, I suppose, in something else entirely.
These inconsistencies will likely have multiple causes: the formatting supplied by the publisher, Amazon's conversion of that to KFX, this plugin's conversion of KFX to EPUB, and calibre manipulation of that EPUB. There is no effort made to maintain the sort of consistency that you would like in this process.

Quote:
Originally Posted by Jaws View Post
1. "Line height" is inconsistently "unitless" in heavily-illustrated books (and this includes, sometimes, tables of data that were embedded as a graphic). In the stylesheet (usually stylesheet.css), some styles will contain each of the following (all of which are/should be valid ePub characteristics):
line-height: 1.29017;
line-height: 129.017%;
line-height: 1.29017em;
This bugs me; it's inconsistent with good laboratory practice — and ability to maintain files over time. It has bugged me about the graphic-design community for several decades, so it may have nothing whatsoever to do with Calibre or any plugin or even KFX.

The reason that I think this may be Calibre is that the first one (the purely unitless one) only appears in "line-height" and margin/padding, never in font size or text-indent. This is a "I'm trying to understand" thing more than a bug report; but...
You can compare various versions of the book if you want to see what changes were introduced by each step. However that could be a lot of work.

The "From KFX" toolbar action can be used to bypass calibre's part of the conversion process to see the CSS produced by this plugin. That will not match exactly the content of KFX format since KFX actually uses something similar to but not the same as HTML/CSS.

To see the actual KFX content in human readable form use the --unpack option of the command line interface supplied by this plugin. "Creating a symbol catalog file" in the first post of this thread has steps needed before this can be accomplished. Making sense of the result is not easy since KFX is undocumented.

You can come close to seeing what the publisher provided to Amazon by obtaining the book in KF8/AZW3 format, available using some older kindle models and apps, and then converting that to EPUB using the KindleUnpack plugin.

Quote:
Originally Posted by Jaws View Post
2. Conversion to different kinds of margin (and padding) shorthands in the ePub stylesheet seems completely random, even within the same book. One might find all of the following in the same ePub stylesheet (I just did this morning):
margin: 0 0 6.24399%;
margin-left: 6.24399%;
margin-left: 0.5em;
margin: 0 0 0 6.24399%;

This one is closer to a bug report than item 1, but the code still "works" so maybe it's not a true "bug." It is in all probability related, somehow, to "what font was specified in the KFX file, whether that font was embedded, and whether that embedded font was subsetted (possibly who subset it, too)." But it's puzzling; specifically, what's puzzling is which form for {editorial comment: STOOOPID choices in the CSS specification for "shorthands", so definitely not a Calibre issue} stating the "margin" is chosen.
This plugin will not produce a margin property with multiple values since there is no KFX equivalent to that. That combining of individual margin-xxx properties must be due to calibre.

Quote:
Originally Posted by Jaws View Post
3. Where, oh where, does the "this book sometimes specifies percentages and sometimes specifies ems" business come from? Is there a way to force conversions to choose one or the other?
Those are two different things that have no equivalent conversion. Percent is used for dimensions that should scale with the size of the containing block and ultimately the size of the screen. em is used when the dimension is intended to scale with the font size chosen by the reader. Both are needed for different cases.
jhowell is offline   Reply With Quote
Advert
Old 04-02-2025, 08:27 AM   #933
Argel
Opinionated [but right]
Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.
 
Argel's Avatar
 
Posts: 281
Karma: 1412
Join Date: Apr 2008
Location: UK
Device: Cybook Gen3, PRS 505, Kindle Int, Oasis, Paperwhite, Scribe
With the latest DeDRM and KFX plugins I can import from my Oasis but not, apparently, from a recent Scribe. Is that par for the course?

Argel

Last edited by Argel; 04-02-2025 at 09:25 AM. Reason: Problem evolving...
Argel is offline   Reply With Quote
Old 04-02-2025, 11:06 AM   #934
miss_p1nky
Connoisseur
miss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enough
 
Posts: 69
Karma: 636
Join Date: Aug 2022
Location: Indonesia
Device: Moon+ Reader Pro
Sorry if it's a bit out of topic but is it safe to update to K4PC 2.7.1?
miss_p1nky is offline   Reply With Quote
Old 04-02-2025, 12:44 PM   #935
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Quote:
Originally Posted by Argel View Post
With the latest DeDRM and KFX plugins I can import from my Oasis but not, apparently, from a recent Scribe. Is that par for the course?
No, it's not. It is possible to import most Kindle ebooks from a Scribe by using the Device view in calibre as long as you have everything set up properly. For the details you should see the Dealing with Kindle ebooks in calibre thread. That is also a good place to ask questions if you are stuck.
jhowell is offline   Reply With Quote
Advert
Old 04-02-2025, 12:45 PM   #936
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Quote:
Originally Posted by miss_p1nky View Post
Sorry if it's a bit out of topic but is it safe to update to K4PC 2.7.1?
No it is not. Any Kindle for PC version newer than 2.4.0 uses new DRM for which no solution is currently available.
jhowell is offline   Reply With Quote
Old 04-03-2025, 12:21 PM   #937
miss_p1nky
Connoisseur
miss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enoughmiss_p1nky will become famous soon enough
 
Posts: 69
Karma: 636
Join Date: Aug 2022
Location: Indonesia
Device: Moon+ Reader Pro
Quote:
Originally Posted by jhowell View Post
No it is not. Any Kindle for PC version newer than 2.4.0 uses new DRM for which no solution is currently available.
Got it, thank you!
miss_p1nky is offline   Reply With Quote
Old 04-03-2025, 12:50 PM   #938
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,408
Karma: 145491800
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Jaws View Post
In case it wasn't clear, I understand that these are all different "acceptable" descriptions for "the same thing" in CSS. (I'll growl some other time about the internal logic of CSS shorthands.) My confusion is at why these are showing up inconsistently in the same document; I do not think it's unique to KFX --> ePub, just more common and more noticeable — and more prone to break during later file maintenance/updating, let alone future formats and devices. (Not even 1992-vintage Quark was this internally inconsistent with measurements.)
I don't care for margin shortcuts. I prefer it typed out the long way. But I sometimes I will edit it and change it from the shorthand.
JSWolf is offline   Reply With Quote
Old 04-03-2025, 03:25 PM   #939
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 45,321
Karma: 168808723
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by Argel View Post
With the latest DeDRM and KFX plugins I can import from my Oasis but not, apparently, from a recent Scribe. Is that par for the course?
Do you have both the Oasis and Scribe serial numbers in your DeDRM configuration?
DNSB is offline   Reply With Quote
Old 04-05-2025, 06:41 AM   #940
Argel
Opinionated [but right]
Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.
 
Argel's Avatar
 
Posts: 281
Karma: 1412
Join Date: Apr 2008
Location: UK
Device: Cybook Gen3, PRS 505, Kindle Int, Oasis, Paperwhite, Scribe
When attempting to convert certain KFX formatted books - not all - I'm getting errors of the kind shown below. Latest KFX plugging installed.
Argel

calibre, version 8.1.1
ERROR: KFX conversion failed: <p><b>[book name redacted]</b><br><br>Exception('box-align right with float right in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align left with float left in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /c60.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align left with float left in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml\nbox-align right with float right in /cWH.xhtml')</p>
Argel is offline   Reply With Quote
Old 04-05-2025, 07:39 AM   #941
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Quote:
Originally Posted by Argel View Post
When attempting to convert certain KFX formatted books - not all - I'm getting errors of the kind shown below. Latest KFX plugging installed.
Argel

calibre, version 8.1.1
ERROR: KFX conversion failed: <p><b>[book name redacted]...
I have not seen that error. I would help to know the ASIN of one or more books exhibiting this problem.
jhowell is offline   Reply With Quote
Old 04-05-2025, 09:06 AM   #942
Argel
Opinionated [but right]
Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.
 
Argel's Avatar
 
Posts: 281
Karma: 1412
Join Date: Apr 2008
Location: UK
Device: Cybook Gen3, PRS 505, Kindle Int, Oasis, Paperwhite, Scribe
KFX conversion error

Quote:
Originally Posted by jhowell View Post
I have not seen that error. I would help to know the ASIN of one or more books exhibiting this problem.
This?

mobi-asin:B002RI9HR0

Argel
Argel is offline   Reply With Quote
Old 04-05-2025, 09:24 AM   #943
Argel
Opinionated [but right]
Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.Argel is no ebook tyro.
 
Argel's Avatar
 
Posts: 281
Karma: 1412
Join Date: Apr 2008
Location: UK
Device: Cybook Gen3, PRS 505, Kindle Int, Oasis, Paperwhite, Scribe
KFX conversion

calibre, version 8.1.1
ERROR: KFX conversion failed: <p><b>Cannot convert The State We're In</b><br><br>Exception("section section-0_1_e06d48a9d308d92c_3055, $269 9178, story story-0_1_d7238a2033f57c48_3054, $269 7332, $276 7475 content type $276 has extra data: ($102: ($306: $308, $307: Decimal('0')))")</p>

mobi-asin:B00ABLJ2GG
Argel is offline   Reply With Quote
Old 04-05-2025, 09:36 AM   #944
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Quote:
Originally Posted by Argel View Post
B002RI9HR0
Quote:
Originally Posted by Argel View Post
B00ABLJ2GG
Unfortunately, neither of those is available from Amazon in my country (USA).
jhowell is offline   Reply With Quote
Old 04-11-2025, 07:40 AM   #945
jhowell
Grand Sorcerer
jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.jhowell ought to be getting tired of karma fortunes by now.
 
jhowell's Avatar
 
Posts: 7,052
Karma: 91577715
Join Date: Nov 2011
Location: Charlottesville, VA
Device: Kindles
Version 2.23.0 - 11 Apr 2025

Handle extra formatting that occurs with images in some books that were converted to KFX by Amazon in 2015. Fixes "Unexpected image style for SVG wrapper".

Handle list-indent when present in a list element. Fixes "content type $276 has extra data: ($102: ($306: $308, $307: Decimal('0')))".

Fix error reporting sometimes failing when using "From KFX". Fixes "AttributeError: 'JobLog' object has no attribute 'html'".

Do not fail to convert books that contain invalid control characters.

Omit unexpected empty entries from the list of fonts in a font-family property.
jhowell is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
KFX conversion, transfer back to library issue. shoelesshunter Conversion 9 04-13-2025 11:15 AM
[Conversion Input] Microsoft Doc Input Plugin igi Plugins 77 03-08-2025 04:04 AM
[Conversion Input] LaTeX Formulas Input Conversion Plugin sevyls Plugins 0 03-23-2015 05:52 AM
[Input Plugin] DOCX Input SauliusP. Plugins 42 06-05-2013 04:01 AM
Looking For MHT Input Conversion Plugin FlooseMan Dave Plugins 4 03-30-2010 05:52 PM


All times are GMT -4. The time now is 09:40 AM.


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