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

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 10-11-2012, 11:53 AM   #1
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 1,444
Karma: 846401
Join Date: Jan 2009
Device: KoboGlo
EPUB without fonts

Hi

I am used to produce EPUB with embedded fonts. I would like to add EPUB without fonts. It's easy to suppress any information about font-family. But for styles, if I wish to give a clean EPUB without font, I need to transform the small-caps styles to reduced capitals styles.

This must be done for paragraph and character styles (spans), probably best in Sigil.

Has somebody any advice to make this transcription automatic?
roger64 is offline   Reply With Quote
Old 10-11-2012, 12:07 PM   #2
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: 37,685
Karma: 18475502
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by roger64 View Post
Hi

I am used to produce EPUB with embedded fonts. I would like to add EPUB without fonts. It's easy to suppress any information about font-family. But for styles, if I wish to give a clean EPUB without font, I need to transform the small-caps styles to reduced capitals styles.

This must be done for paragraph and character styles (spans), probably best in Sigil.

Has somebody any advice to make this transcription automatic?
You have to do it by hand. You have to retype the letters in uppercase. Then apply a span with a class that uses a 75% smaller size.

in CSS...

.smallcaps {
font-size: .75em
}

in the XML...

<p>Here are some <span class="smallcaps">SMALLCAPS</span> for your enjoyment</p>
JSWolf is online now   Reply With Quote
Old 10-11-2012, 12:50 PM   #3
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 6,195
Karma: 4800739
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
It becomes interesting when you have MIXED CASE smallcaps...

Usually, it's not critical to have the letters shown as actual smallcaps, in those cases I just set the conditional styles (ADE only) to use bold (for instance) instead of smallcaps. Readers that support smallcaps will ignore the ADE-only style, and when (if) ADE supports smallcaps I'll simply remove the conditional styles.
Jellby is offline   Reply With Quote
Old 10-11-2012, 02:16 PM   #4
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 1,444
Karma: 846401
Join Date: Jan 2009
Device: KoboGlo
@JSWolf.

This is the downside of small-caps... You can't easily get rid of them...

@Jellby

I have still things to learn to understand your reply. Yes, I enjoy using - sparingly - these mixed case words with true small-caps. And the nicest they are, the hardest to go...

How do you write your mixed case word without true small-caps? Do you need four spans to describe: mixed case? One for M, one for ixed, one for C, one for ase?
roger64 is offline   Reply With Quote
Old 10-11-2012, 03:43 PM   #5
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: 37,685
Karma: 18475502
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Code:
M<span class="smallcaps">ixed</span> C<span class="smallcaps">ase</span>
That's how you do mixed case smallcaps when simulating them. Just two spans are needed in Jellby's example.
JSWolf is online now   Reply With Quote
Old 10-11-2012, 03:55 PM   #6
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 1,444
Karma: 846401
Join Date: Jan 2009
Device: KoboGlo
Quote:
Originally Posted by JSWolf View Post
Code:
M<span class="smallcaps">ixed</span> C<span class="smallcaps">ase</span>
.
OK. Thanks.
roger64 is offline   Reply With Quote
Old 10-11-2012, 04:28 PM   #7
mmat1
Det
mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.
 
mmat1's Avatar
 
Posts: 980
Karma: 1300318
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
Quote:
Originally Posted by roger64 View Post
OK. Thanks.
should read:
M<span class="fakesmallcaps">IXED</span> C<span class="fakesmallcaps">ASE</span>

(with CSS: .fakesmallcaps { font-size: 0.7em } )
mmat1 is offline   Reply With Quote
Old 10-11-2012, 10:59 PM   #8
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 1,444
Karma: 846401
Join Date: Jan 2009
Device: KoboGlo
Quote:
Originally Posted by mmat1 View Post
M<span class="fakesmallcaps">IXED</span> C<span class="fakesmallcaps">ASE</span>

(with CSS: .fakesmallcaps { font-size: 0.7em } )
Thanks for this.

I have a shortcut. I will leave my CSS style-sheet as it is except for this change: search for the small-cap font
Code:
 font-family:'Linux Libertine O C';
and replace it with:
Code:
 font-size:0.7em;
I'll have to process one style after another because I need to check if there is no other font-size specified. And rewrite the text inside in capitals.

For mixed cases though, I should have to parse manually the occurences in the xhtml files and correct them... I think I will probably forget them and leave everything as a fake small-cap... :-)

Last edited by roger64; 10-12-2012 at 11:01 AM. Reason: Edit to suppress text-transform: uppercase
roger64 is offline   Reply With Quote
Old 10-12-2012, 03:29 AM   #9
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 6,195
Karma: 4800739
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
That's risky, the "text-transform" property is not in the ePub spec, some readers may support it though (I'm not sure about ADE, but I believe it doesn't?)
Jellby is offline   Reply With Quote
Old 10-12-2012, 10:59 AM   #10
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 1,444
Karma: 846401
Join Date: Jan 2009
Device: KoboGlo
Quote:
Originally Posted by Jellby View Post
That's risky, the "text-transform" property is not in the ePub spec, some readers may support it though (I'm not sure about ADE, but I believe it doesn't?)
I just came about to realize it. You are right again. It does not work. I have to write manually in capitals as mmat said...

I correct my previous message

Last edited by roger64; 10-12-2012 at 11:02 AM.
roger64 is offline   Reply With Quote
Old 10-12-2012, 08:10 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: 37,685
Karma: 18475502
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by mmat1 View Post
should read:
M<span class="fakesmallcaps">IXED</span> C<span class="fakesmallcaps">ASE</span>

(with CSS: .fakesmallcaps { font-size: 0.7em } )
.75em is fine and .smallcaps is also fine. No need to make it .7em and no need to use .fakesmallcaps.

roger64, do use .75em if you want your smallcaps and not .7em.
JSWolf is online now   Reply With Quote
Old 10-12-2012, 09:02 PM   #12
frostschutz
Linux User
frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.
 
frostschutz's Avatar
 
Posts: 743
Karma: 2031211
Join Date: Sep 2010
Device: iriver Story HD
http://wiki.mobileread.com/wiki/EPubHacks also contains some suggestions about small caps.

Seems to me though as if there just isn't a good solution.

My current calibre settings would filter your smallcaps hack right out. There are too many books with whacky font sizes defined in them - on Smashwords probably because they use Word/DOC as a source? - so font size is one of the properties I filter out when converfixing books.
frostschutz is online now   Reply With Quote
Old 10-12-2012, 09:52 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: 37,685
Karma: 18475502
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by frostschutz View Post
http://wiki.mobileread.com/wiki/EPubHacks also contains some suggestions about small caps.

Seems to me though as if there just isn't a good solution.

My current calibre settings would filter your smallcaps hack right out. There are too many books with whacky font sizes defined in them - on Smashwords probably because they use Word/DOC as a source? - so font size is one of the properties I filter out when converfixing books.
ePub > ePub in Calibre can be a really bad idea. Don't do it. Power up Sigil and fix the ePub from there. Besides, if the ePub is made correctly, there's no need to ePub > ePub.

As for the smallcaps using a font size being a hack, it's how nearly all ePub do it. So if you ePub > ePub all of you do ruin some things like smallcaps.
JSWolf is online now   Reply With Quote
Old 10-13-2012, 03:08 AM   #14
mmat1
Det
mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.
 
mmat1's Avatar
 
Posts: 980
Karma: 1300318
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
Quote:
Originally Posted by JSWolf View Post
.75em is fine and .smallcaps is also fine. No need to make it .7em and no need to use .fakesmallcaps.

roger64, do use .75em if you want your smallcaps and not .7em.
0.7, 0.75 or 0.8; this doesn't make much difference, it's just a matter of personal taste. How to name the class is of minor interest. I just used a quite common term, which is pretty selfexplaining.

The point is, that the letters within the <span> MUST be converted to uppercase (Look at your example a few messages above (#5)). This is the major difference between small caps (Font) and fakesmallcaps.

Last edited by mmat1; 10-13-2012 at 03:10 AM.
mmat1 is offline   Reply With Quote
Old 10-13-2012, 01:51 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: 37,685
Karma: 18475502
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
When I have an ePub that has enough instances of smallcaps, I do convert them to lowercase and use a real smallcaps font. Definitely looks better. I use Charis SIL most of the time and I have a smallcaps version.
JSWolf is online now   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
ePub->ePub conversion with obfuscated fonts DiapDealer Conversion 1 03-17-2012 02:33 PM
Foreign fonts (PL) in epub tntmarek Interead COOL-ER 1 03-04-2011 06:05 PM
ePub embedded fonts JSWolf Ectaco jetBook 9 09-14-2009 08:43 PM
Epub & fonts Nate the great ePub 8 07-28-2009 06:13 AM
ePub + Embedded Fonts Cygfrydd ePub 11 03-02-2009 05:56 PM


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


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