3 ms·
It's a minor problem, but CSS, unlike XUL, doesn't provide a way to crop text in the middle[1][2]. [1] - https://www.w3.org/wiki/Text-overflow_middle_cropping
by xeeeeeeeeeeenu 7y ago
It's a minor problem, but CSS, unlike XUL, doesn't provide a way to crop text in the middle[1][2].
[1] - https://www.w3.org/wiki/Text-overflow_middle_cropping https://www.w3.org/wiki/Text-overflow_middle_cropping
[2] - https://developer.mozilla.org/en-US/docs/Archive/Mozilla/XUL/Attribute/crop https://developer.mozilla.org/en-US/docs/Archive/Mozilla/XUL...
- roca 7y agoCropping text in the middle is extremely hard to spec and implement for general inline CSS. Cropping at the start or end can be implemented as a purely paint-time operation. Cropping in the middle means you have to change the layout, and you have to define the layout of the stuff in the middle that has been cropped away in case someone does element.getClientRects() etc. It is far from obvious how that should work. XUL texboxes avoided this problem by only supporting a single plain text string, but applying that constraint to HTML+CSS would be incredibly ugly (and people soon be complaining about that constraint, anyway).