Open Bug 1290736 Opened 9 years ago Updated 3 years ago

crop attribute on checkbox and radio is ignored

Categories

(Toolkit :: General, defect)

defect

Tracking

()

UNCONFIRMED

People

(Reporter: frommozilla.comhash69, Unassigned)

Details

Attachments

(1 file)

Attached patch proposed patchSplinter Review
User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:47.0) Gecko/20100101 Firefox/47.0 Build ID: 20160623154057 Steps to reproduce: Create a checkbox with crop attribute and limited width: <checkbox crop="center" style="max-width: 7em;" label="141592653589793238462643383"/> Actual results: The label shows full, uncropped, without ellipses in the middle, wider then specified width Expected results: The label should be shown cropped with ellipses in the middle: 1415...3383 The problem is that crop attribute applies only to value attribute of label element and not to child nodes. checkbox.xml and radio.xml however adds text node into label element, hence crop is ignored. The solution is to replace in checkbox.xml and radio.xml xbl:text=label With this: value=label
Attachment #8776378 - Attachment mime type: text/x-patch → text/plain
Attachment #8776378 - Attachment is patch: true
Attachment #8776378 - Flags: review?(bzbarsky)
Comment on attachment 8776378 [details] [diff] [review] proposed patch I'm not the right reviewer for this; it's a toolkit change, not an XBL core change. But the change is wrong anyway, I believe: xbl:text in a label can wrap, iirc, but the value attribute cannot. And checkbox/radio expect their label to be wrappable.
Attachment #8776378 - Flags: review?(bzbarsky) → review-
Component: XBL → General
Product: Core → Toolkit
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: