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

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

Notices

Reply
 
Thread Tools Search this Thread
Old 11-17-2018, 10:56 AM   #1
Velga
Junior Member
Velga began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Apr 2018
Device: Reader Book 1
How can I keep the pevious cover as an image?

I change the book cover with the Calibre program in epub format. When I select and insert a new cover, it just replaces the previous one. However I would like to keep the original cover as a fly page, i.e. as the first image immediately following the new cover when I open the book.
Is it possible to do it in Calibre? If so, what are the procedures?
Velga is offline   Reply With Quote
Old 11-17-2018, 12:48 PM   #2
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 22,501
Karma: 22515246
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: K4NT, Galaxy Tab A, Kobo Aura2
Quote:
Originally Posted by Velga View Post
I change the book cover with the Calibre program in epub format. When I select and insert a new cover, it just replaces the previous one. However I would like to keep the original cover as a fly page, i.e. as the first image immediately following the new cover when I open the book.
Is it possible to do it in Calibre? If so, what are the procedures?
A 'cover' has (must) 2 special attributes that any other images and pages don't.
In the guide section of the BOOKS OPF
Code:
<reference type="cover" title="Cover" href="Text/titlepage.xhtml"/>
and in the Manifest
Code:
<item id="cover" href="Images/cover.jpeg" media-type="image/jpeg"/>
There is also an entry in the Metadata section'
Code:
 <meta name="cover" content="cover" />
That is what Calibre uses to replace, not the filename in itself (I rename those to alt-cvr to avoid confusion). Just to be clear. Calibre is assumed to have the Official cover.

You need to MANUALLY (not automatic without just making them go away) remove the flags (and rename files for safety) BEFORE adding the official cover.
NOTE: Calibre generated coverpages have some additional flags that may trip us up.

I happen to use Sigil (which I first learned), so I will list those steps first.
Have the BOOK file is open in the book editor for either.

Having the 'cover page' open in code view makes it easy to find the pieces;
Right click that filename in the file list: Add semantics... : select 'cover' (it is a Toggle : OK

Look at the <image tag for the file name right click: open tab for Image to jump the file browser to that name
Right click the images file name: Click cover (toggles the tick Off) : OK
OOPS! This does not toggle! BUG? (I usually just declare another existing image as 'cover' so I never tripped on this . That leave editing the OPF)

In Calibres editor: It looks like the OPF edit is also the only way to just remove these flags.
theducks is offline   Reply With Quote
Old 11-17-2018, 02:05 PM   #3
retiredbiker
Connoisseur
retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.retiredbiker is faster than slow light.
 
retiredbiker's Avatar
 
Posts: 67
Karma: 29896
Join Date: May 2013
Location: Ontario, Canada
Device: Kindle KB, Oasis, Ubuntu, Jutoh,Kobo Forma
What I do is much less elegant than theducks solution, but it is pretty easy. Many ways to skin this cat. My workflow:

First I add the new cover I want in the metadata editor, but do not "polish" the book to get it into the book file. Then:

1. (optional) Open the book in the editor. Right click on the existing cover file - the one you want to keep - and export it. (I have a "covers" directory specifically for handling covers, to avoid confusion with other images. I rename it to keep things easy. While it is exported, I also edit it, if I need to, with an external program like GIMP.) [This export is optional, but since I so often edit the image I just always do it. So many old cover shots are badly faded, and I brighten them up.]

2. Still in the editor, I add a brand new html file (menu: file/new file) - which I name altcover.html - , import the exported cover file (menu: file/import files into book), and place code for it in the new html file. I have the code in my master "cheater text file", so I just copy it in and then point to the image file name I want. [If you didn't actually export, just point to the existing cover image]

3. Then I exit the editor, and go ahead and polish the book, with "update the cover in the book files" checked.

Now I have the original cover in a separate file, which is where I want it for TOC reasons, and the nice new cover where Calibre puts it with all the nice correct and complicated coding.

This sounds way more complicated than it is, when I write it out. It actually only takes maybe 20 seconds to actually do it. Of course you can put in more than one alt-cover image this way--as I often do for old pulp SF and mysteries!
retiredbiker is offline   Reply With Quote
Old 11-17-2018, 05:49 PM   #4
BetterRed
null operator
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 11,890
Karma: 10633600
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Before I replace the existing cover.jpeg I save it to the desktop -- right click cover in Book Details select Save cover to disk -- it will save as {title}.jpeg. I open the jpeg in Irfanview and save it as a jng flle. Then I drop the jng file into the Book Details pane, calibre doesn't know about JNG files so it regards it as a format file.

I delete the jpeg and jng file from the desktop and then set about finding and uploading a new cover from the 'net.

I've never wanted to have an alternative cover in a book format file - e.g. the ePub. If I did, I'd have to do what retired biker/the ducks do with an ePub Editor which probably means I'd have to convert the JNG back to JPG.

If I have more than one alternative cover (or any other images) I want to keep for a book, I put them in a multi-image TIF and drop that on the book details panel. This requires the following tweak:

Click image for larger version

Name:	1.jpg
Views:	26
Size:	123.0 KB
ID:	167776

BR
BetterRed 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
Can I get metadata from cover image? The image is correct but all other data is wrong mydjtl Library Management 1 12-14-2017 06:15 PM
paste cover image changes image's size pipistrelosone Editor 1 10-07-2016 10:10 AM
Cover Image dKodiak Calibre 1 02-21-2016 10:53 PM
Cover image isn't displaying as cover image Eugene88 Sigil 3 08-15-2012 05:05 PM
cover image jjh76 Calibre 3 12-30-2011 07:29 AM


All times are GMT -4. The time now is 09:20 PM.


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