You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[This was intended to be a quick query by email, but it is developing into a thread, so i'm copying the discussion here for ongoing discussion.]
my original question:
I'm working on review comments for the ruby section, but i'm a bit stuck because i don't understand the meaning of the term 'glyph area descendant', and i don't see it described anywhere. Could one of you explain what that is? I think it will be important to understand it in order to assess the ruby section.
It is referring to the area tree produced in formatting. See XSL-FO for the conceptual model. The basic hierarchy in this local context is:
block area
line area
inline area
glyph area
A glyph area is an inline area, so this may reduce to the following depending on context:
block area
line area
glyph area
Thus, glyph areas are always descendants of a line area, and may have an intervening inline area or even an inline-block and inline area between the glyph area and the ancestor line area.
Note that XSL-FO classifies a line area as a special type of block area.
I see that for Ruby there are two classes of glyph area, spacing ones and
non-spacing ones. Maybe it would also be an improvement to be explicit and
say "the number of non-spacing glyph areas that are descendants of these
inline areas" where that applies.
So is it equivalent to a character? grapheme cluster? font glyph? something else? I'm trying to figure out what we're counting when looking for N.
Looking at the fact that non-spacing glyphs are omitted from counting,
that effectively leaves the other glyphs, or I suppose grapheme cluster
would be equivalent, since for counting purposes it is irrelevant whether
you include the non-spacing glyph areas or not, and the non-spacing ones
would be combined into the same grapheme cluster.
In other words, "a" and "á" would both count as 1 whether you count the
grapheme clusters or the spacing glyph areas. If you were to count all
the glyph areas then "a" would be 1 and "á" would be 2.
We haven't discussed it but I assume the spec text for ruby is based on
the glyph area counts rather than the other concepts you mention, since it
is directly concerned with how the glyphs should be laid out.
Let IR and IB be, respectively, the inline areas generated by (1) a ruby text container or ruby text annotation and (2) an associated ruby base container or ruby base. Further, let NR and NB, be, respectively, the number of glyph area descendants of these inline areas.
If the value of this attribute is auto, then if NR equals NB, the semantics of withBase apply; otherwise, if NR is less than NB, the semantics of spaceAround or spaceBetween apply, respectively, according to whether NB is less than or equal to one (1) or is greater than one; otherwise (NR is greater than NB), the semantics of center apply.
I'm not sure how this works for the following cases:
the ruby annotation contains the text 'píng'. How many glyph areas is that? What if the annotation is 'píng píng'?
the ruby annotation contains hindi text with conjuncts. Is the conjunct + vowel sign one glyph area? (Conjuncts may or may not be equivalent to grapheme clusters.)
the ruby annotation contains arabic text with the ligature lam-alif, composed of two font glyphs. Is this one glyph area or two?
the ruby annotation contains any arabic text, which is mostly joined up consonants. How many glyph areas is that?
The term glyph area is operationally defined by XSL-FO. The terms spacing and non-spacing are terms of art from the Unicode Standard, see, e.g., combining character, also used font specifications, e.g., OpenType Font.
As presently specified, the definition of glyph area is effectively implementation dependent. That may not be the best we can do, however, so let's consider where it is necessary to improve this.
First, in the context of Japanese text, this isn't a practical problem; however, in the general case, I agree it could be, as some of your examples demonstrate.
the ruby annotation contains the text 'píng'. How many glyph areas is that? What if the annotation is 'píng píng'?
4 and 9, respectively
the ruby annotation contains hindi text with conjuncts. Is the conjunct + vowel sign one glyph area? (Conjuncts may or may not be equivalent to grapheme clusters.)
a reasonable implementation would likely map a single grapheme cluster to a single glyph area for the purpose of counting ruby in this context
the ruby annotation contains arabic text with the ligature lam-alif, composed of two font glyphs. Is this one glyph area or two?
a reasonable implementation would likely include all joined glyphs including any non-spacing marks that apply to them into a single glyph area for the purpose of counting ruby in this context; in other words, it would like extremely strange to separate otherwise joined glyphs or component glyphs
the ruby annotation contains any arabic text, which is mostly joined up consonants. How many glyph areas is that?
The Working Group just discussed Meaning of 'glyph area descendant' ttml2#236.
The full IRC log of that discussion
<nigel> Topic: Meaning of 'glyph area descendant' ttml2#236
<nigel> github: https://github.com//issues/236
<nigel> Nigel: On reviewing this, it appears that there is work to do.
<nigel> Glenn: I missed that - I will tag it for my priority.
Activity
r12a commentedon Jan 26, 2017
[reply by Glenn]
It is referring to the area tree produced in formatting. See XSL-FO for the conceptual model. The basic hierarchy in this local context is:
A glyph area is an inline area, so this may reduce to the following depending on context:
Thus, glyph areas are always descendants of a line area, and may have an intervening inline area or even an inline-block and inline area between the glyph area and the ancestor line area.
Note that XSL-FO classifies a line area as a special type of block area.
r12a commentedon Jan 26, 2017
[my response]
So is it equivalent to a character? grapheme cluster? font glyph? something else? I'm trying to figure out what we're counting when looking for N.
r12a commentedon Jan 26, 2017
[response from Nigel]
"Glyph area" itself is a term widely used in the spec, though there is no
definition for it, since it is an XSL-FO concept - see
https://www.w3.org/TR/2006/REC-xsl11-20061205/#d0e723
I see that for Ruby there are two classes of glyph area, spacing ones and
non-spacing ones. Maybe it would also be an improvement to be explicit and
say "the number of non-spacing glyph areas that are descendants of these
inline areas" where that applies.
Looking at the fact that non-spacing glyphs are omitted from counting,
that effectively leaves the other glyphs, or I suppose grapheme cluster
would be equivalent, since for counting purposes it is irrelevant whether
you include the non-spacing glyph areas or not, and the non-spacing ones
would be combined into the same grapheme cluster.
In other words, "a" and "á" would both count as 1 whether you count the
grapheme clusters or the spacing glyph areas. If you were to count all
the glyph areas then "a" would be 1 and "á" would be 2.
We haven't discussed it but I assume the spec text for ruby is based on
the glyph area counts rather than the other concepts you mention, since it
is directly concerned with how the glyphs should be laid out.
r12a commentedon Jan 26, 2017
[from here, discussion is moved to this issue]
10.2.34 tts:rubyAlign
https://www.w3.org/TR/2016/WD-ttml2-20161117/#style-attribute-rubyAlign
I'm not sure how this works for the following cases:
skynavga commentedon Jan 26, 2017
The term glyph area is operationally defined by XSL-FO. The terms spacing and non-spacing are terms of art from the Unicode Standard, see, e.g., combining character, also used font specifications, e.g., OpenType Font.
As presently specified, the definition of glyph area is effectively implementation dependent. That may not be the best we can do, however, so let's consider where it is necessary to improve this.
First, in the context of Japanese text, this isn't a practical problem; however, in the general case, I agree it could be, as some of your examples demonstrate.
4 and 9, respectively
a reasonable implementation would likely map a single grapheme cluster to a single glyph area for the purpose of counting ruby in this context
a reasonable implementation would likely include all joined glyphs including any non-spacing marks that apply to them into a single glyph area for the purpose of counting ruby in this context; in other words, it would like extremely strange to separate otherwise joined glyphs or component glyphs
see above
Add and use glyph area term; change glyph area descendant elaboration…
skynavga commentedon May 16, 2017
Merge editorial clarifications/elaborations from PR #314.
17 remaining items
css-meeting-bot commentedon Jan 10, 2018
The Working Group just discussed
Meaning of 'glyph area descendant' ttml2#236.The full IRC log of that discussion
<nigel> Topic: Meaning of 'glyph area descendant' ttml2#236<nigel> github: https://github.com//issues/236
<nigel> Nigel: On reviewing this, it appears that there is work to do.
<nigel> Glenn: I missed that - I will tag it for my priority.
Add tts:rubyAlign withBase as at risk (in placeholder status); add gl…
Merge pull request #553 from w3c/issue-0236-glyph-descendant-misc