RE: [css-text] Arabic letters connecting between elements with display: inline



From: James Clark [mailto:jjc@jclark.com]
Sent: Friday, May 23, 2014 6:42 PM
To: Behdad Esfahbod
Cc: Matitiahu Allouche; fantasai; public-i18n-bidi@w3.org; WWW International; www-style@w3.org
Subject: Re: [css-text] Arabic letters connecting between elements with display: inline

On Fri, May 23, 2014 at 2:09 AM, Behdad Esfahbod <behdad@behdad.org<mailto:behdad@behdad.org>> wrote:

I disagree.  Joining should NOT be broken even if font changes.  Using a bold
font to highlight a letter in print is a valid use.  It's hard.  But the
alternative is wrong.  Whether user uses a different font weight or a
different color to highlight shouldn't affect the correctness of the script
behavior.

I am trying to understand what exactly joining across font changes means.

My conceptual model is that you have

a) script runs, consisting of characters with the same script and resolved embedding level, which are broken into
b) font runs, consisting of characters with the same font and size

There are two parts to shaping:

(1) determining which joining form (and thus which GSUB features) to use for each character
(2) applying GSUB/GPOS font features

My understanding is

- color should not affect how characters are split into either script or font runs
- shaping (1) should be done as if applied to each script run independently
- shaping (2) should be done as if applied to each font run independently

Or are you suggesting doing shaping (2) on a font run should take into account information from adjacent font runs?  If so, I don't understand how that works.

James
[SZ] There is an interesting subtle point underlying this discussion. In traditional font terminology, italics and bold are differnet fonts. But, in the way CSS and HTML are used, you select a font family and use emphasis spans to choose among italics and bold. Thus, in CSS/HTML, changing to Bold or Italics is not (strictly) a font change. Furthermore, it would seem that doing joining across these changes is more likely to work (given the Bold and Italic versions of a font family are designed together) than changes between arbitrary fonts. Thus it would seem to make sense to not do breaks for changes between Bold and Italics versus changes in font families.

Steve Z

Received on Saturday, 24 May 2014 05:02:41 UTC