Open Bug 2063495 Opened 1 month ago Updated 1 month ago

[text-box-trim] Clarify support for trimming of negative leading

Categories

(Core :: Layout: Block and Inline, task)

task

Tracking

()

People

(Reporter: sajidanwar, Unassigned)

References

(Blocks 1 open bug)

Details

The line-height property can be set smaller than the font's ascent/descent which can result in negative leading (which is expected behavior). Then text-box-trim can be applied to trim this negative leading, which will actually grow the text box to make the block match the selected edge metrics. This works in Blink and Gecko, but doesn't work in WebKit.

Trimming negative leading seems to me like the correct behavior (and a useful one), but it's not explicit in the specs and is missing from WPTs. So this bug is for two things:

  • File a CSSWG issue to discuss text-box-trim, negative leading, and its support/inclusion in the spec.
  • Add WPTs to test the negative leading case.

(From Jake's Bluesky thread about text-box-trim and negative leading)

Summary: [text-box-trim] Add WPTs for trimming of negative leading → [text-box-trim] Clarify support for trimming of negative leading
You need to log in before you can comment on or make changes to this bug.