04-07-2010, 11:20 PM | #16 |
Wizard
Posts: 1,213
Karma: 12890
Join Date: Feb 2009
Location: Amherst, Massachusetts, USA
Device: Sony PRS-505
|
I made a modified version of TeX Gyre Schola (LPPL) in fontforge, and embedded both the regular version and the modified version in an ePub. Editing the font was easy, since you can set the LBearing/RBearing of an entire span of glyphs in the font with a single command in fontforge. So it only took a couple minutes.
Here's the result. Looks pretty good. There's a minor problem with words at the end of the beginning of the line--see the k e i n e at the end of line 2 and U r s a c h e at the beginning of line 3 and how they're not flush with the edges, but I'm fairly sure I'd have the same problem with spans around each character and adding to the margin. I think I can live with that. The real problem is with ePub renderers that don't support embedded fonts. I gather this includes the damned iPad! I suppose I could define this font as the italic version of a new font family, so if it has to fall back, it'll fall back on italics, but I seem to remember ADE having a problem whereby it would oblique-ify already italic fonts if they're set as font-style: italic;, resulting in an ugly mess--is my memory off on that? Thanks again to Charleski for the idea... Last edited by frabjous; 04-07-2010 at 11:23 PM. |
04-08-2010, 05:59 AM | #17 |
frumious Bandersnatch
Posts: 7,536
Karma: 19000001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
It did the equivalent thing with bold fonts last time I tried, so I bet you are right.
|
Advert | |
|
04-08-2010, 08:35 AM | #18 | |
Wizard
Posts: 1,196
Karma: 1281258
Join Date: Sep 2009
Device: PRS-505
|
Quote:
It doesn't look as if ADE is adding any extra angle to the axis, at least in the desktop version. I think you should be safe using standard italic as a fall-back for readers that take the short bus to school, like iBooks (hopefully this was a result of rushing the hardware out before having the OS properly in place and version 4 will fix it). I hadn't anticipated the problem with line endings. I don't think it looks too bad in the context. You could probably fix it by manipulating the font using the kerning table instead of the sidebearings, so that extra space would be inserted between letters but not between a letter and a space and the size of the letter would remain unchanged. This would be a lot of work though, and you'd have to trust that the reader software will use the kerning table properly. |
|
04-14-2010, 07:49 AM | #19 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
|
|
04-14-2010, 09:18 AM | #20 |
Wizard
Posts: 1,213
Karma: 12890
Join Date: Feb 2009
Location: Amherst, Massachusetts, USA
Device: Sony PRS-505
|
Yeah, that could be it. Anyway, everything seems to working just fine for me with the spaced out font (apart from the slight edges issue mentioned earlier which I can live with).
The only problem I'm having now is that embedding this font forces me to embed the corresponding font for the main text, along with bold/italics/bolditalics versions for it, which generally is fine, except that calibre's viewer won't support multiple font variants from the same family (bug with qt webkit apparently). But I'm not sure too many people use calibre's viewer. |
Advert | |
|
05-15-2011, 04:08 AM | #21 |
Writer
Posts: 101
Karma: 590630
Join Date: Mar 2011
Location: Munich, Germany
Device: none
|
gesperrt
My understanding is, that spacing means a space, following a letter.
So the last letter of the g e s p e r r t word will get a space too, creating the spacing to the following comma. You should exclude the last letter of the word. It is spaced to the preceeding letter, because that letter has a following spacing, but there is no spacing between last letter and comma. Instead of <span style="letter-spacing:3pt">example</span>, xxxxxx use <span style="letter-spacing:3pt">exampl</span>e, xxxxxx George Last edited by GMcG; 05-15-2011 at 04:16 AM. Reason: update |
05-16-2011, 04:52 PM | #22 |
Wizard
Posts: 1,213
Karma: 12890
Join Date: Feb 2009
Location: Amherst, Massachusetts, USA
Device: Sony PRS-505
|
Read the first post: ADE doesn't even support the letter-spacing CSS property.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Small html/css bug | twaits | Calibre | 5 | 01-12-2010 10:26 AM |
HTML and CSS for Dummies | weedfreak | Sigil | 17 | 01-07-2010 09:34 PM |
Problems generating ePub from HTML/CSS | AlexBell | Calibre | 3 | 07-17-2009 05:10 AM |
Supported HTML/CSS tags and properties | Jellby | Bookeen | 9 | 05-04-2008 04:55 PM |
Emphasis Line and Emphasis Dot | mcortez | Sony Reader | 6 | 01-19-2008 07:19 PM |