Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 12-09-2010, 02:47 AM   #1
mboyaci
Member
mboyaci began at the beginning.
 
Posts: 21
Karma: 16
Join Date: Sep 2010
Location: Cyprus
Device: Sony PRS 650, Kindle Paperwhite, Kindle Voyage
Consistent EPUB Conversion

Hi,

I have a library of mobi books and a Sony PRS 650 Reader. I am using Calibre to convert my books to EPUB format for reading on the Sony.

For the most part (about two thirds of the books) the conversion works fine and I get a consistent font size and line spacing. Most of the remaining books end up with font sizes that are very small and a few with font sized that are very large.

I tried the small and medium font size settings on the Sony but there is a big size difference between the two so I cannot get a consistent size for fonts and line spacing across all my books.

I have tried several base font size and line spacing settings in Calibre without much success.

My question is how can I achieve a consistent EPUB font size and line spacing for my mobi books during conversion.

Thanks in advance for any assistance.
mboyaci is offline   Reply With Quote
Old 12-09-2010, 03:41 AM   #2
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
Quote:
Originally Posted by mboyaci View Post
My question is how can I achieve a consistent EPUB font size and line spacing for my mobi books during conversion.
I use a constant setup with the base font and font size key setup as in the attached image. Occasionally some of the lines of a given html might overlap. When I run into that I just set line height to 1.5pts higher than the base font size. For my setup this ends up being 17.5pts for line height.

You can read more about font scaling here in the manual.
Attached Thumbnails
Click image for larger version

Name:	font_size.jpg
Views:	315
Size:	102.4 KB
ID:	62529  
DoctorOhh is offline   Reply With Quote
Old 12-09-2010, 10:47 AM   #3
mboyaci
Member
mboyaci began at the beginning.
 
Posts: 21
Karma: 16
Join Date: Sep 2010
Location: Cyprus
Device: Sony PRS 650, Kindle Paperwhite, Kindle Voyage
Thanks for the reply. I have read the manual several times.

I have tried something along the lines you suggested (limited key) before but I will try your suggestion as well.

I selected three books that have different font sizes on the Sony and opened them in Firefox (EPUB reader) as well as Adobe Digital Editions. The fonts all look the same. I also increased and decreased the font sizes in these books and retried them in Firefox and Adobe and I can see the changes. So the problem seems to be related to my Sony.

Which device should I select for output to the PRS 650 (I now use plain Sony Reader)?
mboyaci is offline   Reply With Quote
Old 12-09-2010, 03:14 PM   #4
Agama
Guru
Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.
 
Agama's Avatar
 
Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
I always remove the class="calibre.." attributes from ePubs and then replace the stylesheet.css with my own, specifically tailored for a Sony PRS-300. You could try this and see if it helps - or just copy some of these styles as a test.

Note that all the font sizes are defined in EMs to scale according to the zoom level, (the PRS-300 only has S, M, L).

(To use this file in an ePub, rename the attachment to stylesheet.css).
Attached Files
File Type: txt stylesheet.txt (1.8 KB, 240 views)
Agama is offline   Reply With Quote
Old 12-10-2010, 06:23 AM   #5
mboyaci
Member
mboyaci began at the beginning.
 
Posts: 21
Karma: 16
Join Date: Sep 2010
Location: Cyprus
Device: Sony PRS 650, Kindle Paperwhite, Kindle Voyage
I examined the txt file and it is very impressive. What if anything do I need to change for the PRS 650? Also do I enter this in the extra css section in Calibre?

And by the way the EPUB books that are problematic on the Sony are fine on my iPad.
mboyaci is offline   Reply With Quote
Old 12-10-2010, 06:34 AM   #6
mboyaci
Member
mboyaci began at the beginning.
 
Posts: 21
Karma: 16
Join Date: Sep 2010
Location: Cyprus
Device: Sony PRS 650, Kindle Paperwhite, Kindle Voyage
I also have the russified 1.05f firmware on my reader so the userStyle.css file is exposed. Can I enter the contents of the userstyle.txt in this file?
mboyaci is offline   Reply With Quote
Old 12-10-2010, 02:09 PM   #7
Agama
Guru
Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.
 
Agama's Avatar
 
Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
Save the file anywhere on your computer and then rename it to stylesheet.css, (the forum wouldn't let me upload it as a css). Open calibre and use tweak ePub to explode an ePub, (one that calibre has generated by conversion as this will have stylesheet.css in it), into its separate folders/files. Copy the saved stylesheet.css over the top of the one in the exploded folder. Close the window which opened for the explosion and hit the "rebuild ePub" button. Send the updated ePub to your reader and see if it's any good.

As for PRS-300 specifics, it's mainly just the font sizes that I have defined. My base font is 0.875em which corresponds to the Small zoom on my reader. I only get S, M, L and I don't know how many zoom level the PRS-650 supports. If you find things too small then simply scale up all the font-sizes in the css file. I have also used a right margin to reduce collision with the annoying small, grey page numbers which Sony readers insist on displaying down the right hand side. (Maybe Sony have got rid of this on the 650).

I have no idea what russified means. Who is Russ?
Agama is offline   Reply With Quote
Old 12-10-2010, 03:35 PM   #8
mboyaci
Member
mboyaci began at the beginning.
 
Posts: 21
Karma: 16
Join Date: Sep 2010
Location: Cyprus
Device: Sony PRS 650, Kindle Paperwhite, Kindle Voyage
Thanks for the detailed info.

Russified refers to Sony readers with a modified firmware. The firmware is modified by Russian enthusiast(s) thus "Russified". It makes the userStyle.css visible on the Sony Reader. This way any modifications made to userStyle.css gets applied to all EPUB books on the device.
mboyaci is offline   Reply With Quote
Old 12-10-2010, 03:53 PM   #9
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: 73,897
Karma: 128597114
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 Agama View Post
I always remove the class="calibre.." attributes from ePubs and then replace the stylesheet.css with my own, specifically tailored for a Sony PRS-300. You could try this and see if it helps - or just copy some of these styles as a test.

Note that all the font sizes are defined in EMs to scale according to the zoom level, (the PRS-300 only has S, M, L).

(To use this file in an ePub, rename the attachment to stylesheet.css).
But how can you be sure that your CSS will fit the converted eBook's CSS requirements? You can't. So really, it's a crap shoot and my guess is you'll lose more then you will win.
JSWolf is offline   Reply With Quote
Old 12-10-2010, 05:07 PM   #10
Agama
Guru
Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.
 
Agama's Avatar
 
Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
Nearly all my books comes from plain text sources to which I then apply markdown, so I can indeed be sure that my CSS will fit the eBook and also achieve a consistent style, which mboyaci was asking about.

Your response also seems a bit off topic and doesn't appear to offer mboyaci any useful suggestions.

@mboyaci : Just have a go and see how it works out for you. My stylesheet isn't intended as a one size fits all your books but as a starting point to help you to achieve your goal.
Agama is offline   Reply With Quote
Old 12-10-2010, 05:12 PM   #11
Agama
Guru
Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.
 
Agama's Avatar
 
Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
Quote:
Originally Posted by mboyaci View Post
Russified refers to Sony readers with a modified firmware. The firmware is modified by Russian enthusiast(s) thus "Russified". It makes the userStyle.css visible on the Sony Reader. This way any modifications made to userStyle.css gets applied to all EPUB books on the device.
Interesting. I will look it up on this forum.
Agama is offline   Reply With Quote
Old 12-10-2010, 05:15 PM   #12
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: 73,897
Karma: 128597114
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 mboyaci View Post
Hi,

I have a library of mobi books and a Sony PRS 650 Reader. I am using Calibre to convert my books to EPUB format for reading on the Sony.

For the most part (about two thirds of the books) the conversion works fine and I get a consistent font size and line spacing. Most of the remaining books end up with font sizes that are very small and a few with font sized that are very large.

I tried the small and medium font size settings on the Sony but there is a big size difference between the two so I cannot get a consistent size for fonts and line spacing across all my books.

I have tried several base font size and line spacing settings in Calibre without much success.

My question is how can I achieve a consistent EPUB font size and line spacing for my mobi books during conversion.

Thanks in advance for any assistance.
Simple answer is.. YOU CAN'T. Not all Mobipocket eBooks are alike. And because of this, you won't get consistent conversions. The best you can do is after the conversions of the ones you don't like, you can go into the ePub and edit the CSS to fit your needs. I do it all the time and in the end, I have an ePub that looks good.
JSWolf is offline   Reply With Quote
Old 12-10-2010, 05:17 PM   #13
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: 73,897
Karma: 128597114
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 Agama View Post
Nearly all my books comes from plain text sources to which I then apply markdown, so I can indeed be sure that my CSS will fit the eBook and also achieve a consistent style, which mboyaci was asking about.

Your response also seems a bit off topic and doesn't appear to offer mboyaci any useful suggestions.

@mboyaci : Just have a go and see how it works out for you. My stylesheet isn't intended as a one size fits all your books but as a starting point to help you to achieve your goal.
The way you suggested using your CSS was to remove body="calibre" with just body and then replace the CSS with yours. That didn't look like a good suggestion. So I said so.
JSWolf is offline   Reply With Quote
Old 12-10-2010, 05:45 PM   #14
Agama
Guru
Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.Agama ought to be getting tired of karma fortunes by now.
 
Agama's Avatar
 
Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
Quote:
Originally Posted by JSWolf View Post
The way you suggested using your CSS was to remove body="calibre" with just body and then replace the CSS with yours. That didn't look like a good suggestion. So I said so.
I DO remove all the class="calibre.." attributes from all the xhtml tags and my stylesheet then automatically supplies all the necessary styling and provides instant consistency to my ePubs. (It also has the beneficial side-effect of making each ePub file quite a bit smaller).

Having text/markdown as my source ensures that I don't meet with any esoteric tags which would upset this scheme. I don't have any mobi books but given that the conversion is still to ePub, the principle should still apply. If some of the less often encountered xhtml tags turn up in the conversion then the stylesheet can easily be updated.
Agama is offline   Reply With Quote
Old 12-10-2010, 06:10 PM   #15
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: 73,897
Karma: 128597114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
I know for sure that there is no one size fits all CSS. You need the CSS that fits the XML/HTML.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Epub Conversion jcwald Calibre 3 09-10-2010 08:38 AM
epub conversion problems Reko Calibre 0 08-24-2010 12:03 AM
Epub 1.0.5 Conversion JenJ Introduce Yourself 7 08-07-2010 08:24 AM
PDF to EPUB conversion jfontana Calibre 2 03-17-2010 03:09 AM
Trying to get consistent look to all output daveps Calibre 0 03-08-2010 02:18 PM


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


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