content icon indicating copy to clipboard operation
content copied to clipboard

font-stretch vs font-width SVG attribute: clarify the renaming

Open herrstrietzel opened this issue 9 months ago • 3 comments

MDN URL

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/font-stretch

What specific section or headline is this issue about?

Deprecation notice

What information was incorrect, unhelpful, or incomplete?

The deprecation notice should include a hint that the preferred CSS 4 property name would be font-width.

In fact this is simply a new (re)naming convention. It doesn't really change anything how browsers map available width variants.

The font-stretch property name was indeed quite misleading as it implied some sort of glyph scaling (analogous to SVG lengthAdjust) which it never did.

However, it is very unlikely Browsers will remove font-stretch in the next 10 years. Especially with regards to slower adoptions by non-browser applications (similar to xlink:href)

What did you expect to see?

Please consider to add:

or copy the notice from the aforementioned CSS article for the SVG

Note: The font-stretch property was renamed to font-width in the CSS Fonts specification. To preserve compatibility, the specification retains font-stretch as an alias for the font-width property.

Do you have any supporting links, references, or citations?

No response

Do you have anything more you want to share?

No response

MDN metadata

Page report details
  • Folder: en-us/web/svg/reference/attribute/font-stretch
  • MDN URL: https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/font-stretch
  • GitHub URL: https://github.com/mdn/content/blob/main/files/en-us/web/svg/reference/attribute/font-stretch/index.md
  • Last commit: https://github.com/mdn/content/commit/3c83d88f02f33f4066224e9f624a17dd2a0b0d19
  • Document last modified: 2025-04-16T15:02:49.000Z

herrstrietzel avatar Feb 24 '26 00:02 herrstrietzel

hey, @pepelsbey Are you still on this? I'd love to take this, @Josh-Cena

dataCenter430 avatar Mar 04 '26 12:03 dataCenter430

hey, @pepelsbey Are you still on this? I'd love to take this, @Josh-Cena

Sure, go ahead. Feel free to ping me for review, since I recently documented font-width CSS property.

pepelsbey avatar Mar 04 '26 13:03 pepelsbey

Sent a PR https://github.com/mdn/content/pull/43567

pepelsbey avatar Mar 24 '26 14:03 pepelsbey