Closed
Bug 244058
Opened 21 years ago
Closed 21 years ago
BUTTON elements forced to native look even with CSS unsupported by native theme (e.g. background)
Categories
(Camino Graveyard :: HTML Form Controls, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Camino0.8
People
(Reporter: stuart.morgan+bugzilla, Assigned: stuart.morgan+bugzilla)
References
()
Details
(Keywords: fixed1.7)
Attachments
(1 file, 2 obsolete files)
890 bytes,
patch
|
mikepinkerton
:
review+
bryner
:
superreview+
asa
:
approval1.7+
|
Details | Diff | Splinter Review |
<button> elements are always drawn native, but the consensus seems to be that we
should revert to gfx for styled <buttons> since they can be way more complex
than a simple <input> button. This will let us support background images and
colors for <button>s so buttons with light text colors are still readable (see
travelocity link).
I'll hopefully have a fix soon to add NS_BUTTON_BEVEL support to IsWidgetStyled.
Assignee | ||
Comment 1•21 years ago
|
||
CCing pinkerton and bryner, since they'll have to approve it at some point.
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•21 years ago
|
||
After messing around with this and considering, my opinion is that we should
always use gfx-style <button>s. They can contain arbitrary HTML, so there's no
good way of knowing if styled buttons make sense. If we use IsWidgetStyled,
we'll get weird, inconsisntant results. Example:
<button style="background-color:red; color:blue"><div>Click</div></button>
<button><div style="background-color:red; color:blue">Click</div></button>
These should look basically the same, but any use of styling detection for
theming will give us one themed button and one unthemed. Since there's no good
way to tell, and I think we should have both consistency and stylability, I
vote for gfx-buttons (especially since I don't think most people would use a
<button> over an <input> if they weren't doing semi-complex things with them).
Assignee | ||
Comment 3•21 years ago
|
||
Nominating for 0.8, since I really think we need to do *something* to make sure
we aren't allowing foreground w/o background on <button>s. Otherwise, sites with
such buttons (like travelocity) are unusable.
Target Milestone: --- → Camino0.8
Assignee | ||
Updated•21 years ago
|
Attachment #149109 -
Flags: review?(pinkerton)
Comment 4•21 years ago
|
||
Comment on attachment 149109 [details] [diff] [review]
Disables <button> theme support
r=pink.
Attachment #149109 -
Flags: superreview?(bryner)
Attachment #149109 -
Flags: review?(pinkerton)
Attachment #149109 -
Flags: review+
Comment 5•21 years ago
|
||
instead of removing all code for bevel buttons in the theme code, just don't
use -moz-appearance in css for <button> tag
Attachment #149109 -
Attachment is obsolete: true
Updated•21 years ago
|
Attachment #149109 -
Flags: superreview?(bryner)
Updated•21 years ago
|
Attachment #149239 -
Flags: superreview?(bryner)
Updated•21 years ago
|
Attachment #149239 -
Flags: superreview?(bryner) → superreview+
Assignee | ||
Comment 6•21 years ago
|
||
Hm... I thought I tried that and it made <button>s use NS_THEME_BUTTON instead
of BUTTON_BEVEL, and thus get themed sometimes.
Assignee | ||
Comment 7•21 years ago
|
||
Yeah, I just double-checked. Pink's patch will make <button>s into
NS_THEME_BUTTONs, and will thus be themed if unstyled (and will in fact go from
themed when enabled to gfx when disabled, which is extra bad).
Assignee | ||
Comment 8•21 years ago
|
||
The better and working patch is to replace
-moz-appearance: button-bevel;
margin: 5px 2px 0px 2px;
padding: 0px;
border-width: 2px 4px 4px 4px;
With
-moz-appearance: none;
I don't think we want to get rid of the line for moz-focus-inner, 'cause that's
just ugly. We still get feedback from the button-push.
No source tree handy at the moment, so I can't attach a new patch, but I tested
this and it works.
Assignee | ||
Comment 9•21 years ago
|
||
Always makes <button> un-themed, adds the moz-focus-ring back in for <button>s
Attachment #149239 -
Attachment is obsolete: true
Assignee | ||
Comment 10•21 years ago
|
||
Comment on attachment 149584 [details] [diff] [review]
working better patch
We presumably need an a= for the 1.7 branch as well, so please request that
from the appropriate person.
Attachment #149584 -
Flags: superreview?(bryner)
Attachment #149584 -
Flags: review?(pinkerton)
Updated•21 years ago
|
Attachment #149584 -
Flags: superreview?(bryner) → superreview+
Comment 11•21 years ago
|
||
Comment on attachment 149584 [details] [diff] [review]
working better patch
a=asa (on behalf of drivers) for checkin to 1.7
Attachment #149584 -
Flags: approval1.7+
Comment 12•21 years ago
|
||
Comment on attachment 149584 [details] [diff] [review]
working better patch
r=pink
Attachment #149584 -
Flags: review?(pinkerton) → review+
Comment 13•21 years ago
|
||
landed on trunk and branch
Status: ASSIGNED → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•