Open Bug 1751421 Opened 3 years ago Updated 7 months ago

Word stretching is not applied to justified Tamil text when large gaps appear between words.

Categories

(Core :: Layout: Text and Fonts, enhancement)

Firefox 96
enhancement

Tracking

()

UNCONFIRMED

People

(Reporter: ishida, Unassigned)

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:96.0) Gecko/20100101 Firefox/96.0

Steps to reproduce:

Tamil words can be quite long, which can cause problems for justified text, especially in narrow columns, because large gaps can appear between words, or at the end of a line if only one word fits on that line. To mitigate this, especially in the absence of hyphenation, lines that are justified in Tamil should automatically stretch words to fit in the following cases.

When only one word fits on a line, that word should be stretched to fit the whole line.

Where a small number of words appears on a line, the words on that line may also be stretched, so as to reduce the inter-word spacing.

However, a distinctive feature of Tamil is that the adjustments applied should equally expand the space between all unconnected, spacing glyphs (including the space between various vowel-signs and their base), rather than solely putting space around syllables, grapheme clusters or even code points.

For examples and additional explanations see https://w3c.github.io/iip/gap-analysis/taml-gap#issue80_justification

Actual results:

interactive test, With CSS set to text-align:justify; text-justify:auto, when large gaps appear between justified words in Tamil the browser will automatically reduce the gaps by stretching words on the affected line.
https://github.com/w3c/line_paragraph_tests/issues/35
Gecko: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:94.0) Gecko/20100101 Firefox/94.0
Blink: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36
Webkit: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.1 Safari/605.1.15

interactive test, With CSS set to text-align:justify; text-justify:auto, when a narrow column means that only one Tamil word fits on a line, the word will be stretched to fit the whole width of the column
https://github.com/w3c/line_paragraph_tests/issues/36
Gecko: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:94.0) Gecko/20100101 Firefox/94.0
Blink: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36
Webkit: ❌ Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.1 Safari/605.1.15

interactive test, When inter-character spacing is applied to Tamil, equal space is added between all unligated spacing glyphs, including between the glyphs forming vowel-signs and their base characters, but ligated glyphs and non-spacing combining characters are not separated from the base.
https://github.com/w3c/line_paragraph_tests/issues/36
Gecko: ✅❌ Inter-character spacing is applied, but inter-glyph spacing is not. Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:96.0) Gecko/20100101 Firefox/96.0
Blink: ❌ No inter-character spacing is applied. Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.71 Safari/537.36
Webkit: ❌ No inter-character spacing is applied. Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.2 Safari/605.1.15

The Bugbug bot thinks this bug should belong to the 'Core::Layout: Text and Fonts' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.

Component: Untriaged → Layout: Text and Fonts
Product: Firefox → Core
You need to log in before you can comment on or make changes to this bug.