Open Bug 487348 Opened 17 years ago Updated 3 years ago

XUL <label> ignores CSS letter-spacing

Categories

(Core :: XUL, defect)

defect

Tracking

()

People

(Reporter: Dolske, Unassigned)

Details

(Keywords: testcase)

Attachments

(2 files)

497 bytes, application/vnd.mozilla.xul+xml
Details
516 bytes, application/vnd.mozilla.xul+xml
Details
Attached file Testcase
Setting letter-spacing on a XUL label doesn't seem to have any effect. Works for a <description>, though. In this simple testcase, the 1st pair of lines (using <label>) look the same (tested both OS X and Linux). The 2nd and 3rd pairs of lines (using <description> and <html:div>) correctly look different.
Attached file Testcase #2
It's not a difference between label/description, but between specifying the text in the 'value' attribute or as child text.
Maybe this is an optimization? When using the 'value' attribute you get a (simple) nsTextBoxFrame otherwise you get a nsBlockFrame with one ore more child nsTextFrames: http://mxr.mozilla.org/mozilla-central/source/layout/base/nsCSSFrameConstructor.cpp#4223
Severity: normal → minor
Keywords: testcase
Yeah, the xul text frame doesn't use textruns, so it doesn't support things like letter-spacing and various things like that. If you know you're not going to wrap lines and there aren't any issues in your case with using blocks inside boxes, you should just use <description>Text</description>.
Severity: minor → S4
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: