Closed
Bug 452969
Opened 16 years ago
Closed 16 years ago
[FIX]File upload control has text too gray, barely visible
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
RESOLVED
FIXED
mozilla1.9.1b1
People
(Reporter: mariusads, Assigned: bzbarsky)
References
Details
(Keywords: access, regression)
Attachments
(4 files, 1 obsolete file)
6.07 KB,
image/png
|
Details | |
235 bytes,
text/html
|
Details | |
9.72 KB,
patch
|
Details | Diff | Splinter Review | |
8.96 KB,
patch
|
dbaron
:
review+
dbaron
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.0.1) Gecko/2008070208 Firefox/3.0.1
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.0.1) Gecko/2008070208 Firefox/3.0.1
The name of the file uploaded in an file upload control is shown with a very light gray, which is barely noticeable. People that change gamma setting may not even see it. See picture.
Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Expected Results:
Font color should be darker, if not normal black.
Reporter | ||
Comment 1•16 years ago
|
||
Reporter | ||
Comment 2•16 years ago
|
||
That control actually has these css rules attached:
background:#252721 none repeat scroll 0%;
border-color:#000000 rgb(70, 70, 70) rgb(70, 70, 70) rgb(0, 0, 0);
border-style:solid;
border-width:1px;
color:#E7E7E7;
font-family:Verdana,Arial,Helvetica,sans-serif;
font-size:13px;
In Firefox 2 the rules worked fine, now in Firefox 3 the background is always white but the color of text is enforced, which makes it barely visible.
I can only imagine how many websites would have this problem and how many programmers/designers don't know yet that this issue messes up the page design and accessibility.
Updated•16 years ago
|
Status: UNCONFIRMED → NEW
Component: Theme → Layout: Form Controls
Ever confirmed: true
Product: Firefox → Core
QA Contact: theme → layout.form-controls
Updated•16 years ago
|
Updated•16 years ago
|
Keywords: regression
Assignee | ||
Comment 3•16 years ago
|
||
This seems to be a native-theming screwup. In particular, adding "-moz-appearance: none" to the CSS for that input makes everything work fine.
Really, there are two bugs here as far as I can tell:
1) We don't drop native theming for the kids of the file control. We probably
should, but native-theming-dropping doesn't handle inheritance very well,
apparently.
2) The native theme only paints backgrounds and lets colors be painted by other
layout code. The result, in this case, is this bug.
Really, I doubt we can fix #2, so I guess we better fix #1.
Component: Layout: Form Controls → Style System (CSS)
OS: Windows Server 2003 → All
QA Contact: layout.form-controls → style-system
Hardware: PC → All
Version: 1.9.0 Branch → Trunk
Assignee | ||
Comment 4•16 years ago
|
||
Assignee | ||
Comment 5•16 years ago
|
||
Assignee: nobody → bzbarsky
Status: NEW → ASSIGNED
Attachment #336426 -
Flags: superreview?(dbaron)
Attachment #336426 -
Flags: review?(dbaron)
Assignee | ||
Updated•16 years ago
|
Summary: File upload control has text too gray, barely visible → [FIX]File upload control has text too gray, barely visible
Attachment #336426 -
Flags: superreview?(dbaron)
Attachment #336426 -
Flags: superreview-
Attachment #336426 -
Flags: review?(dbaron)
Attachment #336426 -
Flags: review-
Comment on attachment 336426 [details] [diff] [review]
This seems to do the trick
>+ // Have to do this check right here, so that later UA rules
>+ // won't clobber values[i] with eCSSUnit_Dummy.
I'm having trouble understanding this comment. (The code makes sense, but I can't make sense of the comment.)
>+ childValues[i]->GetUnit() == eCSSUnit_DummyInherit))
It also seems like you could just have a single array, and when you're done, if you have any dummy inherits, you clear all the dummy inherits back to null and set everything else to dummy when you step up to the parent. And this way, you could probably do what you're doing as a recursive step as a loop instead.
Does that make sense? (Maybe it doesn't, in which case I'll reconsider...)
Assignee | ||
Comment 7•16 years ago
|
||
> I'm having trouble understanding this comment.
Initially I didn't do the early return there, just kept going and had the return in the default: case in the switch, but that doesn't work, of course, because a lower-precedence UA rule would change "some other value" into eCSSUnit_Dummy. I can remove the comment or reword; I agree that as written it's confusing.
> seems like you could just have a single array ...
Hmm. Yeah, that seems like it should work. You're right that it's better that way; I'll make that change.
Assignee | ||
Comment 8•16 years ago
|
||
Attachment #336426 -
Attachment is obsolete: true
Assignee | ||
Comment 9•16 years ago
|
||
If you have any bright ideas on testing this, let me know... putting a text and button input next to each other doesn't look quite the same. :(
Attachment #338421 -
Flags: superreview?(dbaron)
Attachment #338421 -
Flags: review?(dbaron)
Comment on attachment 338421 [details] [diff] [review]
Same as diff -w
r+sr=dbaron. Sorry for the delay.
Attachment #338421 -
Flags: superreview?(dbaron)
Attachment #338421 -
Flags: superreview+
Attachment #338421 -
Flags: review?(dbaron)
Attachment #338421 -
Flags: review+
Assignee | ||
Comment 11•16 years ago
|
||
Pushed changeset 177b174c83e4. I have no idea how to write a test for this. :(
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Flags: in-testsuite?
Resolution: --- → FIXED
Comment 12•16 years ago
|
||
Boris, is it possible to backport this to the 1.9.0 branch ?
Assignee | ||
Comment 13•16 years ago
|
||
Yes, but I'm not sure we should be doing this: this isn't seriously breaking large numbers of sites, and it's not security-related in any way.
If someone wants to try to convince drivers to take this on branch, go for it.
Updated•16 years ago
|
Target Milestone: --- → mozilla1.9.1b1
Version: Trunk → 1.9.0 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•