RESOLVED FIXED 24762
Text-indent is not supported on <option> elements
https://bugs.webkit.org/show_bug.cgi?id=24762
Summary Text-indent is not supported on <option> elements
Ada Chan
Reported 2009-03-23 11:57:40 PDT
Text-indent is not supported on option elements. For example: <select> <option>no text-indent</option> <option style="text-indent: 100px;">100px text-indent</option> </select> The second option should be much wider due to the text-indent, causing the select to be wider also.
Attachments
Patch (6.91 KB, patch)
2009-03-23 12:06 PDT, Ada Chan
no flags
Second try. (8.39 KB, patch)
2009-03-23 16:15 PDT, Ada Chan
adele: review+
Ada Chan
Comment 1 2009-03-23 12:06:52 PDT
mitz
Comment 2 2009-03-23 12:39:40 PDT
Comment on attachment 28858 [details] Patch Setting the review flag
mitz
Comment 3 2009-03-23 13:40:05 PDT
Comment on attachment 28858 [details] Patch I think you can make the PopupMenuStyle changes in all platform, even if only Windows uses the extra members now. For the RenderMenuList.cpp change, the problem is that not all Windows platform ports use PopupMenuWin.cpp and themeWin.css. Perhaps it should be a RenderTheme decision whether to support text-indent. Then RenderMenuList can as the theme if it should apply the indent to the width, and PopupMenuWin could do the same.
mitz
Comment 4 2009-03-23 13:40:41 PDT
(In reply to comment #3) > Then RenderMenuList can as the theme s/as/ask/
Ada Chan
Comment 5 2009-03-23 16:15:33 PDT
Created attachment 28872 [details] Second try. Added RenderTheme::popupOptionSupportsTextIndent().
Adele Peterson
Comment 6 2009-03-23 16:32:38 PDT
Comment on attachment 28872 [details] Second try. I think you have extra spacing on the last line here. > + maxOptionWidth = max(maxOptionWidth, optionWidth); > + } else if (!text.isEmpty()) > + maxOptionWidth = max(maxOptionWidth, style()->font().floatWidth(text)); > } Looks good! r=me.
Ada Chan
Comment 7 2009-03-23 16:46:59 PDT
Fixed in r41923.
Note You need to log in before you can comment on or make changes to this bug.