RESOLVED FIXED219735
Implement ascent-override, descent-override, and line-gap-override
https://bugs.webkit.org/show_bug.cgi?id=219735
Summary Implement ascent-override, descent-override, and line-gap-override
Tobi Reif
Reported 2020-12-10 02:39:31 PST
It would be very useful if you could implement ascent-override, descent-override, and line-gap-override. More info: https://bugs.chromium.org/p/chromium/issues/detail?id=800693 (especially comments #20, #30 and #31) https://tobireif.com/non_site_stuff/test_case_for_font_position_report_yet_another_font/ https://www.w3.org/TR/css-fonts-4/#font-metrics-override-desc
Attachments
the general issue (12.17 KB, image/png)
2021-02-15 01:52 PST, Tobi Reif
no flags
Tobi Reif
Comment 1 2020-12-11 02:31:31 PST
Chrome supports it (tested on MacOS vs Windows).
Radar WebKit Bug Importer
Comment 2 2020-12-17 02:40:18 PST
Tobi Reif
Comment 3 2021-01-08 03:33:03 PST
Here's one reason why it's important to implement this feature: https://tobireif.com/posts/ensuring_the_correct_vertical_position_of_large_text/ (And there's another reason listed in the post below "Another use case".)
Tobi Reif
Comment 4 2021-02-15 01:52:30 PST
Created attachment 420285 [details] the general issue Given that the issue can be as severe as in the attached screenshot, please consider assigning a high priority to implementing this feature.
Tobi Reif
Comment 5 2021-03-23 03:43:55 PDT
Chrome and Edge support the properties, and they are currently getting implemented in Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=1681691 I hope that they will get implemented in Safari soon.
Tobi Reif
Comment 6 2021-06-25 03:15:28 PDT
Chrome, Edge, and Firefox support it. Safari now is the only major browser which doesn't support this feature. Please implement it soon.
Rick
Comment 7 2022-06-22 04:03:10 PDT
+1 for Safari implementation!
Fu liang
Comment 8 2022-07-17 18:24:28 PDT
+1 for Safari implementation!
Roel Nieskens
Comment 9 2022-09-05 06:43:43 PDT
+1! Any news on when/if this will land?
Jesse Bennett-Chamberlain
Comment 10 2022-09-05 07:59:23 PDT
+1 these properties (along with size-adjust) would be useful for any application that allows users to change their preferred typeface.
Tim Nguyen (:ntim)
Comment 11 2022-10-15 08:41:57 PDT
*** Bug 229726 has been marked as a duplicate of this bug. ***
Cesar
Comment 12 2022-11-30 09:18:29 PST
+1 - Would like to see updates on this
Tyler Sticka
Comment 13 2024-05-15 12:54:34 PDT
+1 Would love to see this happen!
Gabrien Symons
Comment 14 2024-08-20 07:26:33 PDT
+1 to have in Safari!
m.hohengarten
Comment 15 2024-12-03 01:49:15 PST
+1 I'd love to see this 3 years old standard feature on every other browser engine (Blink/Geko supports it since 2021) becoming a standard in all browser engines.
paul.c.pederson
Comment 16 2025-04-21 10:33:39 PDT
Believe it or not the lack of support for this feature in safari is costing us thousands of dollars. @Tim Nguyen (:ntim) is there any way we could get this moved up in the team's queue?
shierote
Comment 17 2026-06-30 23:53:09 PDT
This has been open five years now, with steady interest but no status update. Every other major engine shipped these descriptors in 2021, the spec is stable, and the scope looks modest — so it'd help the community to understand where this stands. @Tim Nguyen (:ntim) Is there a blocker or design concern holding it back, or is it just unstaffed? If it's the latter, is this something an outside contributor could reasonably pick up with some guidance? Happy to help however is useful.
shierote
Comment 18 2026-07-01 18:10:28 PDT
I've implemented all three descriptors (ascent-override, descent-override, line-gap-override) in PR #68431: https://github.com/WebKit/WebKit/pull/68431 Feedback from the Text component owners would be very welcome.
shierote
Comment 19 2026-07-06 04:25:40 PDT
I opened https://github.com/WebKit/WebKit/pull/68736 as a parser-only first step for the CSS Fonts 4 @font-face metric override descriptors, behind a testable feature flag. This supersedes the earlier full implementation PR and follows the review feedback to split the work.
EWS
Comment 20 2026-07-09 10:58:43 PDT
Committed 316829@main (ab58f961d64a): <https://commits.webkit.org/316829@main> Reviewed commits have been landed. Closing PR #68736 and removing active labels.
shierote
Comment 21 2026-07-09 16:45:57 PDT
Update: I split the implementation into smaller steps, as suggested in review. The first step has now landed in PR #68736: https://github.com/WebKit/WebKit/pull/68736 This adds parser support for the CSS Fonts 4 @font-face metric override descriptors behind a testable feature flag. Follow-up steps are planned for: 1. exposing the descriptors through FontFace / CSSFontFaceDescriptors; 2. applying the descriptors to font metrics.
shierote
Comment 22 2026-07-09 19:42:58 PDT
Update: I have opened the follow-up PR for exposing these descriptors through FontFace / CSSFontFaceDescriptors: https://github.com/WebKit/WebKit/pull/69062 Applying them to font metrics remains planned as the next step.
Tobi Reif
Comment 23 2026-07-10 02:21:19 PDT
> Update: I have opened the follow-up PR for exposing these descriptors through FontFace / CSSFontFaceDescriptors: > > https://github.com/WebKit/WebKit/pull/69062 > > Applying them to font metrics remains planned as the next step. The status/resolution of this ticket has been set to "resolved/fixed". But it seems there are (at least) the above steps left to do. I think it would be appropriate to set the status to "reopened".
shierote
Comment 24 2026-07-10 05:37:42 PDT
> The status/resolution of this ticket has been set to "resolved/fixed". > > But it seems there are (at least) the above steps left to do. > > I think it would be appropriate to set the status to "reopened". This bug was automatically closed when the parser-only patch landed, but the full implementation is not complete yet. I don’t have permission to reopen it myself. Could someone please reopen it until the remaining work is completed?
Tobi Reif
Comment 25 2026-07-10 06:57:57 PDT
Implementation is not complete yet.
Tobi Reif
Comment 26 2026-07-10 07:01:12 PDT
(It's not shown as part of the above comment, but I reopened the ticket.)
EWS
Comment 27 2026-07-10 14:46:42 PDT
Committed 316933@main (db0ac8a9cb38): <https://commits.webkit.org/316933@main> Reviewed commits have been landed. Closing PR #69062 and removing active labels.
shierote
Comment 28 2026-07-10 19:27:30 PDT
Update: I’ve opened the final implementation PR: https://github.com/WebKit/WebKit/pull/69154 This applies the three metric override descriptors to font metrics and should complete their implementation behind the existing testable feature flag. Shipping/default-on remains a separate decision.
Tobi Reif
Comment 29 2026-07-10 22:08:55 PDT
Reopening because Implementation is not complete yet.
shierote
Comment 30 2026-07-25 06:15:41 PDT
Update: the final PR is now in good shape and awaiting final review (thanks to @fantasai’s reviews): https://github.com/WebKit/WebKit/pull/69154 Looking for a review from someone with expertise in fonts or CSS, particularly to validate the FontCache sharing approach — @vitorroriz or another relevant reviewer. Once that is approved, the feature should be fully supported, apart from enabling the existing flag by default.
EWS
Comment 31 2026-08-05 19:55:28 PDT
Committed 318680@main (5ee6c014d2b8): <https://commits.webkit.org/318680@main> Reviewed commits have been landed. Closing PR #69154 and removing active labels.
shierote
Comment 32 2026-08-05 20:41:03 PDT
Update: the implementation tracked by this bug is now complete and landed in 318680@main, so keeping this resolved as FIXED is appropriate. The remaining shipping work is: - promote `CSSFontFaceMetricOverrideDescriptorsEnabled` from `testable` to `stable` (in progress); - enable it by default on all ports (after an appropriate testing period)
EWS
Comment 33 2026-08-06 03:43:17 PDT
Committed 318699@main (2a7c5b4538a9): <https://commits.webkit.org/318699@main> Reviewed commits have been landed. Closing PR #71020 and removing active labels.
shierote
Comment 34 2026-08-06 19:30:09 PDT
Now stable and enabled by default.
shierote
Comment 35 2026-08-06 19:33:57 PDT
(In reply to shierote from comment #32) > Update: the implementation tracked by this bug is now complete and landed in > 318680@main, so keeping this resolved as FIXED is appropriate. > > The remaining shipping work is: > > - promote `CSSFontFaceMetricOverrideDescriptorsEnabled` from `testable` to > `stable` (in progress); > - enable it by default on all ports (after an appropriate testing period) Correction: The remaining work is not enabling it by default (that's already done). It's removing the flag itself, which will happen after some time has passed.
Note You need to log in before you can comment on or make changes to this bug.