W3C home > Mailing lists > Public > public-css-archive@w3.org > February 2018

Re: [csswg-drafts] [css-fonts] Propose adding lang as a font-face descriptor

From: Patrick Dark via GitHub <sysbot+gh@w3.org>
Date: Wed, 07 Feb 2018 07:25:31 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-363680363-1517988330-sysbot+gh@w3.org>
I think it should be more clear what problem needs solving:

Given a traditional Chinese document with a run of Japanese text, a property declaration such as `font-family: "Traditional Chinese Font", "Simplified Chinese Font", "Japanese Font";` should just work with glyphs from the appropriate script displayed, including characters with one code point but multiple, language-specific glyphs.

Instead of using a language descriptor, a better approach may be to use a language exclusion descriptor. So, for the aforementioned "Traditional Chinese Font", one might declare something along the lines of `exclude-lang: "*-hans", "*-jpan"` in its `@font-face` rule and this would prevent it from being used to render text marked as `ja-jpan`, `zh-hans`, `zho-hans`, etc.

This approach also avoids having to make a decision about how to label a font that contains characters from multiple languages.

GitHub Notification of comment by patrickdark
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1744#issuecomment-363680363 using your GitHub account
Received on Wednesday, 7 February 2018 07:25:38 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:24 UTC