w3c / csswg-drafts

CSS Working Group Editor Drafts
https://drafts.csswg.org/
Other
4.52k stars 672 forks source link

[css-text-4] hanging-punctuation property not language-specific enough #10141

Open macnmm opened 8 months ago

macnmm commented 8 months ago

https://drafts.csswg.org/css-text-4/#hanging-punctuation-property

The list of hanging characters includes characters that should not hang if processing layout according to Japanese rules. At least there should be modifications to the behavior based on the language conventions being emulated.

For example, Latin period characters are used in Japanese layout, but should not hang; but Japanese period and comma should.

There are likely language-specific hanging conventions that would dictate the need for language-specificity in the behaviors.

fantasai commented 1 month ago

The rules for hanging-punctuation: start | end are CJK rules at the moment. If we add rules for other languages, that should probably be dependent on the content language of the containing block (defaulting to CJK, for compatibility).