Intent to Prototype: CSS kashida justification

29 views
Skip to first unread message

Helmut Januschka

unread,
4:33 PM (1 hour ago) 4:33 PM
to blink-dev
Contact emails
hjanu...@gmail.com

Explainer
https://static.januschka.com/i-41431127/index.html

Specification
https://drafts.csswg.org/css-text-4/#text-justify-property

Summary
Adds the `kashida` value to `text-justify`, allowing authors to justify Arabic and other cursive-script text by elongating connections within words. The inherited `text-kashida-space` percentage controls how justification space is divided between kashida elongation and inter-word spacing. CL: https://chromium-review.googlesource.com/c/chromium/src/+/7957320 Launch Chromium with: --enable-blink-features=CSSTextJustifyKashida,CSSTextKashidaSpace Then visit: https://static.januschka.com/i-41431127/

Blink component
Blink>Layout>Inline

Web Feature ID
Missing feature

Motivation
Browsers currently justify Arabic and other cursive scripts primarily by widening spaces between words. Typographically, these scripts commonly justify text by elongating the connecting strokes within words. Web authors have no way to request this behavior in Chromium or control the split between elongation and word spacing. Internet Explorer and EdgeHTML previously supported `text-justify: kashida` and `text-kashida-space`, and content written for that behavior now silently falls back to Latin-style word spacing. This feature restores an author-controlled mechanism while keeping inserted tatweels confined to the shaping buffer, so DOM text, selection, search, copying, accessibility, and editing remain unchanged.

Initial public proposal
https://docs.google.com/document/d/1OP8CfU_rE5-nllcjiZK6EO-E99HwmKHhuJLPDryiG3M/edit

Goals for experimentation
None

DevTrial instructions
https://static.januschka.com/i-41431127

Requires code in //chrome?
False

Tracking bug
https://issues.chromium.org/issues/41431127

Non-OSS dependencies

Does the feature depend on any code or APIs outside the Chromium open source repository and its open-source dependencies to function?

None. The implementation uses ICU, HarfBuzz, and Blink's existing shaping and inline-layout infrastructure.

Estimated milestones

No milestones specified



Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

A CSSWG proposal will request addition of the `kashida` value to `text-justify`, the `text-kashida-space` property, and interoperable rules for selecting and applying elongation opportunities.

Link to entry on the Chrome Platform Status
https://chromestatus.com/feature/5072607092277248?gate=5171673868402688

This intent message was generated by Chrome Platform Status.
Reply all
Reply to author
Forward
0 new messages