-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why exclude hebrew and arabic proportional reference fonts? #237
Comments
My understanding here is that the text is not meant to exclude Hebrew and Arabic glyphs per se but to exclude them from the definition of reference metrics. I suspect this is because in those languages (and others I guess) the same code point results in multiple variant glyphs dependent for example on the position within a word, so it is not straightforward to tabulate the metrics per code point. I would suggest that we add a Note explaining that the exclusion applies only to reference font metrics and is not meant to suggest that the code points themselves should not be supported. |
Hmm, then this appears to be worse than i thought. Tying that back to https://w3c.github.io/imsc/imsc1/spec/ttml-ww-profiles.html#reference-fonts-1
suggests to me that line-breaking is only properly supported for proporitionally-spaced fonts for a few Latin/Greek/Cyrillic languages. That's a much bigger issue, and suggests a very old fashioned, almost archaic, and highly western-biased mindset about how to handle text. Also, the CJK scripts, which are normally mono-spaced by nature, are not included in the reference fonts either, so presumably line-wrapping isn't supported for them either? (Note btw the extract above is missing the word 'on' after depends.) |
No. Any combination of character and font family can be used by authors, and line breaking is specified for all such combinations -- using the UAX 14 algorithm. Processors have to support mandatory metrics only for a smaller set of font family and characters. |
@r12a I think that line is not supposed to be an exhaustive list of the things that the flow of text depends on, just an example. It certainly isn't supposed to exclude anything that is needed for line wrapping. Possibly I have not understood your concern about that text though? The main thing is the normative text:
This is independent of line breaking. Perhaps the wording you quoted could be written in a more precise way? |
Sorry to be so slow in understanding all this. I think some additional explanations in the spec to address these topics would be useful. There were similar questions coming from other members of the i18n WG. I guess this is just a profile, but my reading of 7.3 seemed to indicate that text flow (which may not involve line wrapping) was only done by counting characters, and i see no mention of UAX 14. Perhaps there needs to be something that explains the relationship between sections 7.2, 7.3, App A and App B, and the main TTML spec(?) |
@r12a I'm trying to understand this reading - from the words present, what led you to that? by the way, §7.4 includes a mandatory requirement to support UAX 14 via the
So it is there... |
wrt linebreak-uax14, ah! - not sure why my search of the document didn't find that.
Perhaps because of the following text in the section 7.3 Reference Fonts
I may be leaping to unwarranted conclusions, but it seemed to indicate that if you want to avoid clipping, you need to use reference fonts. |
Not necessarily - you could use named fonts that correspond to specific font resources you know will be available at presentation time. The intent of this, in my understanding, is to solve the general problem that when authoring a document the actual font that will be used at presentation time is not known, particularly when a generic font family name is used. This requirement sets a reasonable expectation of the size of the rendered text (sequence of glyphs) so that other fixed size elements such as regions can be given an appropriate dimension to include all that text. This is a particular issue when content elements cannot grow to fit, or when scrollbars cannot usefully be made available, which is the case when presenting text overlaid on video. It also allows the author to meet the accessibility requirement to position text to avoid important areas of underlying video. |
Ok. This is not the intent of the sentence and there is not conformance terminology in the sentence that would compel implementation behavior. I am happy to remove the sentence if it causes more confusion than it helps. |
I agree that sentence could usefully be changed but I would not remove it altogether. I would simply qualify it by appending "when using the generic font family names monospaceSerif or proportionalSansSerif". |
I plan to generate a PR based on #237 (comment) |
I don't believe that this applies for Hebrew. Hebrew isn't a cursive script like Arabic. Also, most other scripts than the simple alphabetic ones like Latin/Cyrillic/Greek or CJK, glyphs vary based on context. So the list of exclusions needs to be much bigger than just Arabic - the spec should, i'd have thought, at least mention that just using monospaced fonts for Arabic doesn't solve the real problem here. To be honest, I'm worried that the current approach will just reinforce the tendency that already exists to tailor processors just for 'easy' scripts and languages, rather than really making developers aware of the need to consider a world wide audience when they create their technology. |
Yes, it would be good to note best practices. |
@r12a I had imagined that HEBREW LETTER FINAL KAF and HEBREW LETTER KAF, for example, were the same code point and the selected glyph would be based on position within the word, but it turns out that they are distinct code points. I stand corrected on the Hebrew point. |
Yep, that's a result of legacy technologies and keyboards (and typewriters). Same applies to Greek wrt sigma. It doesn't really apply in the same way to any other scripts i can think of. (background reading: http://r12a.github.io/scripts/tutorial/part3#word-final and https://r12a.github.io/uniview/?charlist=%CF%83%CF%82) |
Thank you @r12a - those links are extremely useful! |
A. Reference Fonts
https://www.w3.org/TR/ttml-imsc1.0.1/#reference-fonts
Why are codepoints for
hebr
andarab
excluded from the proportional font list? Actually, monospaced fonts are particularly problematic for arabic script text, since it creates an appearance of baseline stretching between narrow glyphs, and can cause difficulty in rendering wide characters elegantly (such as س). So if there was a preference one way or the other, i'd expect it to be biased towards proportional fonts.The text was updated successfully, but these errors were encountered: