Re: [CSS Text/G.C. for P.M.] Hyphenation & ligatures

2009/2/23 Jonathan Kew <jonathan@jfkew.plus.com>:
> On 23 Feb 2009, at 10:41, thomas wrote:
>> Some fonts have ligatures which are not specified in the Unicode
>> standard.  For instance, in 'Linux Libertine', U+E03C (private range)
>> is a ligature for 'tt'.
>>
>> To use the special ligature, one can write:
>>
>>  fi&#xE03C;ed
>
> This would be a really bad thing to do. Suppose the reader doesn't have this
> particular font, but does have a different font that uses U+E03C for
> something quite different -- such as an arbitrary dingbat or a non-Latin
> character, which would appear as "junk", or even an "ll" or "lm" or "bb"
> ligature, which would completely change the meaning of the text.

This is perfectly true for a web page. But say I want to print an html
page. I could do some replacements to improve the typographic quality.
I know I own the font anyway. In a private environment, doing
s/tt/\uE03C/ is not a problem.

Actually, something like this would be nice:
<span style='hyphenate: auto; @fontexists("the_font") { apply_lig:
"tt", "\uE03C" }'>fitted</span>

> Font developers should not be encoding ligatures like this in the private
> use area, and authors should not use such codes in text. The ligatures
> should be accessed using "smart font" technologies such as OpenType, AAT,
> and/or Graphite. The text should contain the underlying "tt" characters; it
> is up to the font-rendering mechanism to display this using an appropriate
> ligature, if one is provided.
>
> The same applies to more common ligatures such as "fi", or Arabic ligatures
> like "lam-alef". Don't use "presentation forms" like U+FB01 or U+FEFB, etc,
> in text; use the individual characters, and leave ligature formation to the
> fonts.

OK, but the font rendering mechanism needs hints. How could it know if
I want to use fake or real small caps, normal or old-style digits, a
simple bullet or an ornament? CSS provides no way to give it a hint.

++
Thomas

Received on Monday, 23 February 2009 15:36:27 UTC