View Full Version : Baffled again - css, san serif sometimes


brewt
12-11-2009, 07:51 PM
I'm really givin' this my ever-lovin-best, here, and know no more of what to make of it. Perhaps the kindly folks can tell me (once again) what the hay-el I am doing wrong:

Built me a demo typeface page, for eventual font embedding. Epub-ified it in Calibre.
However, despite Valid XHTML and Valid CSS, and it all looking like it should just work, I am seeing Serifed Fonts being displayed in ADE for the H1 and H2. In fact, anywhere I call SanSerif fonts (outside of the Title), it always comes out Serifed.

I'm not expecting the actual font to be called; but having it call a SanSerif font would be nice.

It's not like I've royally hosed it, either (as usual). Calibre Viewer, Dreamweaver, Firefox, Browser, and (ack)Word all show it working just fine. ADE, tho, is determined to make it not happen.

And just because I think it's funny, I've built a version with Indesign and full font embedding. THEN it works in ADE, but is funny looking in Calibre - the headings and titles are fairly non-bold-like. I'm sure there's reason (like not using a real bold version of Frutiger in my calls).

Attached are the usual suspects: source, calibre source, epub(s), pic.

Despite all my relentless earlier criticisms of InDesign, it does do this font rendering thing pretty well - should I revisit it?

-bjc

brewt
12-11-2009, 08:14 PM
Hey, never mind, I figured it out!

ADE doesn't like Small Caps, which I had my h1 and h2 are set to do. Removerating that, and it's sans serif ahoy.

Indesign wouldn't export them as small caps, so, ergo, it worked there.

Does this mean that small caps don't work on a reader?

-bjc

Valloric
12-11-2009, 08:43 PM
And just because I think it's funny, I've built a version with Indesign and full font embedding. THEN it works in ADE, but is funny looking in Calibre - the headings and titles are fairly non-bold-like. I'm sure there's reason (like not using a real bold version of Frutiger in my calls).

Calibre uses the QWebView component from Qt, and it has problems with embedded font variants. It doesn't display them. So if your book has an embedded font in several variants--normal, bold, italic--it will only ever display the normal version.

Sigil uses the same Qt component and therefore has this issue as well. It's the main reason why font embedding is still absent from Sigil... there's little point trying to embed a font if you can't preview all the font variants.

ADE is (sadly) your best benchmark for embedded fonts.

brewt
12-12-2009, 11:35 AM
Yeah, but gosh, if the font is NOT embedded, and the small-caps text transform is called, it seems to me that ADE should simply ignore the call, and not change the font to something else (to default from SansSerif) AND ignore the call.

Indesign solves the problem by ignoring the call on export (small-caps looks right in ID4), so, to have that come out, one would need a real SC font.

Can anybody pronounce b-u-g-(s)?

Has anyone started a catalog of what works on what epub-display-mechanism and what doesn't? (no, not volunteering, here. Lazy, you know).

-bjc

brewt
12-12-2009, 12:30 PM
And, as a point of order, text-variant:smallcaps; doesn't work in Mobi, either. they come out lower case.

In Dreamweaver, they look like all caps.

So, despite them showing up just fine in Word and Indesign, an electro-book don't do them so well.

-bjc

JSWolf
12-13-2009, 09:38 AM
Hey, never mind, I figured it out!

ADE doesn't like Small Caps, which I had my h1 and h2 are set to do. Removerating that, and it's sans serif ahoy.

Indesign wouldn't export them as small caps, so, ergo, it worked there.

Does this mean that small caps don't work on a reader?

-bjc
I use Fontin most of the time with ePub and there is a smallcap veriation of the font that I've used to replace the "let's make the uppercase smaller but not quite get the size correct to simulate smallcaps" that is used.