Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 08-07-2026, 01:10 PM   #1
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: 84,527
Karma: 153744815
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Request for Enhancement

I have an eBook with some really long filenames. I cannot easily tell this filename on the left is the filename I have in the code view. I'd like to be able to select the image filename and have it select the image in the left.

This is the image name and there are a lot of images with stupid filenames like this. And there are similar stupid filenames with the same image just smaller. The smaller images don't need to exist. But they are also incorrectly in the code.

image-119892204_3511918198871636_8155329703591030692_n-sRGB-264-70.jpg

<div class="heading-image-size-container">
<img alt="" src="images/llama-sRGB-264-70.jpg"/><img alt="" height="120" src="images/llama-sRGB-120-70.jpg" width="120"/>
</div>
JSWolf is offline   Reply With Quote
Old 08-07-2026, 05:52 PM   #2
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: 46,446
Karma: 29634066
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
so select all the image files and right click and do a bulk rename to nice small names.
kovidgoyal is offline   Reply With Quote
Advert
Old 08-07-2026, 09:21 PM   #3
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: 53,837
Karma: 181886195
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
And do the same for the text files. There is no real reason to worry about human readable names but there is no reason to have overly long filenames.

One recent ePub file I edited had the entire title&aubtitle/author name/chapter&number, the ebook ISBN and a date string embedded in every filename (a fan of Amazon's long titles???). I used Sigil's standard rename to rename the chapter files and a regex rename to clean up the image files. The stylesheets were individually renamed.
DNSB is offline   Reply With Quote
Old 08-08-2026, 10:07 AM   #4
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: 84,527
Karma: 153744815
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 kovidgoyal View Post
so select all the image files and right click and do a bulk rename to nice small names.
That worked. Thanks. I didn't think about a bulk rename.
JSWolf is offline   Reply With Quote
Old 08-10-2026, 02:39 AM   #5
Jaws
JCL Punch-Card Collector
Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.
 
Posts: 122
Karma: 606562
Join Date: Jun 2014
Location: Antarctica
Device: Aggressively Device Independent
Some publishers are extremely fond of beginning the filename of every file in an epub with the ISBN… and, about half the time, it's not the epub's ISBN, but a paper edition of the book. It's just as annoying as the interminable series of _split000x that results from converting a mobi.

As Kovid says, bulk renaming makes this much easier — and then one can spot the "also by" page in a fifteen-year-old book, and the "here's the first (oops, unedited and unproofread) chapter in the next book in the series," and other ad material, then do with it what is appropriate. Reduces the overall file size and speeds loading on old hardware, too! If you don't like having multiple file extensions for the same kinds of files (for example, both .jpeg and .jpg, or .html and .xhtml), there's also a tool for that in the editor. The bulk-renaming tool leaves the extensions alone.

If one has a scheme for standard naming, that makes later creating an omnibus edition (single epub containing several previously-published, related books — a single-volume The Lord of the Rings, for example) a lot easier, and a lot easier to debug when there are any problems, especially with subtly-different stylesheet entries that have the same name.
Jaws is offline   Reply With Quote
Advert
Old 08-10-2026, 06:28 AM   #6
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: 84,527
Karma: 153744815
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
If one has a scheme for standard naming, that makes later creating an omnibus edition (single epub containing several previously-published, related books — a single-volume The Lord of the Rings, for example) a lot easier, and a lot easier to debug when there are any problems, especially with subtly-different stylesheet entries that have the same name.
The Lord of the Rings series can be had as one eBook. But yes, I know what you mean. The thing is, why use Vellum when it's one of the worst programs ever for creating ePub? It creates code that 's awful. Heck, It's a lot easier to take a proper (with styles) Word document and make an ePub from there.
JSWolf is offline   Reply With Quote
Old 08-10-2026, 04:40 PM   #7
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: 53,837
Karma: 181886195
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by JSWolf View Post
[B]The thing is, why use Vellum when it's one of the worst programs ever for creating ePub? It creates code that 's awful. Heck, It's a lot easier to take a proper (with styles) Word document and make an ePub from there.
Vellum is not intended for those who want to get down and dirty with the innards of their ebooks. It is intended for people who want to write their book in a word processor, save it as a .docx and then be able to generate ebooks to be sent to a publisher. Does your calibre conversion from a .docx include the capability to be readable on an old Kindle without KF8/KFX support?

Half the complexity in the stylesheets you whinge about is simply trying to have an ebook that will look decent on any ePub, mobi, KF8 and KFX renderer regardless of screen size. For mobi, you also need to use pixels to size images, etc. Hence, the use of two stylesheets, one of which is used for media queries.
DNSB is offline   Reply With Quote
Old 08-10-2026, 04:56 PM   #8
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: 84,527
Karma: 153744815
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 DNSB View Post
Vellum is not intended for those who want to get down and dirty with the innards of their ebooks. It is intended for people who want to write their book in a word processor, save it as a .docx and then be able to generate ebooks to be sent to a publisher. Does your calibre conversion from a .docx include the capability to be readable on an old Kindle without KF8/KFX support?

Half the complexity in the stylesheets you whinge about is simply trying to have an ebook that will look decent on any ePub, mobi, KF8 and KFX renderer regardless of screen size. For mobi, you also need to use pixels to size images, etc. Hence, the use of two stylesheets, one of which is used for media queries.
I've never seen the need for the media queries. Kindlegen converts to Mobi just fine. So as long as the ePub is not too complicated, it works well. KF8 works from Kindlegen. I know calibre does a rather good job at ePub > KF8. Vellum tries to do too much and gets it wrong.

There is no reason why the eBook needs two different size images. There is no reason the filenames need to be stupidly long. There is no reason not to display the cover properly when the cover image is in the internals of the eBook.

Another thing is gets wrong is backwards comparability. It's using mega quires for non-Amazon things and not all older software will work with these media queries. You don't do @media not amzn-mobi. You put your non-mobi code in the main CSS and put what you need in @media amzn-mobi. This is all wrong with Vellum.

If you are reading the last Vellum eBook I edited as ePub with a Kobo, you will see every chapter header will have two images. One thw wrong sie and they should be centered, but they won't be because of the media-queries. This eBook is available on Overdrive o if you get from from there and do not edit it and do not sync, it will be ePub and will have errors.

Vellum needs to understand backwards comparability. Vellum gets that so very wrong for no reason at all. All Vellum has to do is drop non-Mobi media queries and only use media queries for Mobi.

Vellum gets too much too wrong.
JSWolf is offline   Reply With Quote
Old 08-10-2026, 05:20 PM   #9
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: 53,837
Karma: 181886195
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Jon, Jon, Jon...

If Vellum dropped the media queries for KF8/azw3, then how is a mobi renderer supposed to know which one to use? How is a non-mobi renderer know which on to use? Early RMSDK versions happily display both images since it's understanding of media queries was rudimentary.

My personal choice would be a regex search that removed the entire <img height=...data-AmznRemoved-M8="true"/> code from any appearances for an ePub conversion. Admittedly, this requires using KindleUnpack not a calibre conversion to preserve most of the original input file and not munge the two Vellum stylesheets into a single stylesheet. Not to mention that KindleUnpack does not split files requiring you to play games with the conversion options to avoid that nasty happening.

Oddly enough, I have 4 groups of saved searches just for Vellum generated ePubs after which removing empty divs and spans does a very decent job of cleanup.

Code:
<div class="title-page-publisher-logo-size-container">
          <a class="link-contains-image" href="http://www.knockon.com"><img src="../images/00003.jpeg" alt="Knock On Publishing" class="title-page-publisher-logo-image" data-AmznRemoved="mobi7"/>
          <img height="75" alt="Knock On Publishing" class="title-page-publisher-logo-image1" src="../images/00002.jpeg" width="172" data-AmznRemoved-M8="true"/></a>
        </div>
You also seem to forget that Vellum can output an ePub or an ePub intended for publishing by Amazon. The ePub only such as ends up on Kobo, for some odd reason, does not have the 'data-AmznRemoved="mobi7"' or the 'data-AmznRemoved-M8="true"' media queries.

As for your whinging about dual images? As mentioned earlier, one saved search cleans those up very nicely. That is the main reason I have that saved search collection since it automates the cleanup process. Stupid repetitive tasks are begging to have the computer take care of them.

Last edited by DNSB; 08-10-2026 at 05:25 PM. Reason: Added comment about dual images.
DNSB is offline   Reply With Quote
Old 08-11-2026, 08:24 PM   #10
Jaws
JCL Punch-Card Collector
Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.Jaws ought to be getting tired of karma fortunes by now.
 
Posts: 122
Karma: 606562
Join Date: Jun 2014
Location: Antarctica
Device: Aggressively Device Independent
Quote:
Originally Posted by JSWolf View Post
The Lord of the Rings series can be had as one eBook. But yes, I know what you mean. The thing is, why use Vellum when it's one of the worst programs ever for creating ePub? It creates code that 's awful. Heck, It's a lot easier to take a proper (with styles) Word document and make an ePub from there.
I wouldn't use Vellum, either, but then I have dabbled in LaTeX, Quark, PageMaker… and even direct-to-PostScript 1 (for a particularly difficult graphic back in the 90s). Vellum is terrible for anything other than straight narrative text with only one or maybe two levels of subheadings, only the occasional illustration, and no super- or subscripting anywhere. A nonexperimental novel doesn't need more than that, so it's probably ok for that purpose.
Jaws is offline   Reply With Quote
Old 08-11-2026, 08:33 PM   #11
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: 84,527
Karma: 153744815
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
You only need the media queries for Mobi. I've never seen an ePub that needs media queries for KF8. All the ePub I've converted to KF8 have not had an issue. So if you need so do something specific for Mobi, then you can use specific Mobi media queries.

And as Mobi is now dead at Amazon, there's no need for Vellum to have any media queries. Vellum's media queries are a sloppy mess.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Simple enhancement request al1cre Conversion 2 07-09-2012 05:45 PM
Feature / Enhancement Request _reader Recipes 2 05-16-2012 10:24 AM
Enhancement Request tacheson Calibre 7 09-30-2011 12:01 PM
Enhancement Request: Catalog Zebri Calibre 2 06-18-2010 09:14 AM
Enhancement Request? emellaich Calibre 2 06-13-2009 12:13 AM


All times are GMT -4. The time now is 07:23 AM.


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