Closed Bug 43371 Opened 24 years ago Closed 24 years ago

[CBX][FIX-html.css]<select size="1"> css rendering problem

Categories

(Core :: Layout: Form Controls, defect, P3)

x86
Windows 98
defect

Tracking

()

VERIFIED WORKSFORME
Future

People

(Reporter: jameslariviere, Assigned: rods)

Details

(Keywords: css1, Whiteboard: [nsbeta3-])

Attachments

(2 files)

DESCRIPTION:

The ,select size="1". background-color of the "drop down arrow" renders 
incorrectly when the general select is declared with input, such as:

input, select {
	background-color: #fff;
	color: #006;
	}

then next declare

select[size="1"] {
	background-color: #000;
	color: #0f0;
	}

if you omit the input (shown in test case 2) the <select>s render okay.


STEPS TO REPRODUCE:

view test case 1 for "INCORRECT" rendering.
view test case 2 for "CORRECT" rendering.

ACTUAL RESULTS:

The <select size="1"> renders with a background-color white when the background-
color for <select size="1"> is declared black.

view test case 1

EXPECTED RESULTS:

THe <select size="1"> should render with the typical "gray" drop down arrow. 

view test case 2

DOES NOT WORK CORRECTLY ON:

Win98 build 200062020 (6-20-00-m17 nightly build)
The problem is the button inside the select picks up the new "input" rule 
specified in the doc's "style" tag.

Hmmmm, this will take some thinking.


This bug has been marked "future" because the original netscape engineer working 
on this is over-burdened. If you feel this is an error, that you or another 
known resource will be working on this bug,or if it blocks your work in some way 
-- please attach your concern to the bug for reconsideration. 
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Target Milestone: --- → Future
Hey Rod,

I think I may have a fix or at least lead you in the right direction.


	select > input[type="button"] {
	background-color: inherit;
	}

What's cool is that let's say you do a :focus for your select the button turns 
the same background-color as the select (in my case it's green).

I think I like this behavior better than what we come to expect (color gray) 
for this button all the time.

I'll post a test case.
I tried this last week and it didn't work, but you gave me an idea. If I add 
!important to the rule then it works:

select > input[type="button"] {
  background-color: inherit !important;
}

Nominating for nsbeta3
Keywords: nsbeta3
Summary: <select size="1"> css rendering problem → [FIX-html.css]<select size="1"> css rendering problem
Whiteboard: Fix in hand
Target Milestone: Future → M17
Marking nsbeta3+
Keywords: correctness, css1
Whiteboard: Fix in hand → [nsbeta3+]Fix in hand
actually this doesn't work. It picks up the background color of select which is 
white. I am going to set the button color to "buttonface", then leave this open 
and down grade it from nsbeta3 
Changed the background-color for the arrow button to "buttonface", this is the 
best we are going to get for nsbeta3. The way the style context hierarchy set up 
for the selects and the containing button it wants to inherit the bg color of 
the select which is white.

setting this bug to nsbeta3-, and marking as future
Whiteboard: [nsbeta3+]Fix in hand → [nsbeta3-]
Target Milestone: M17 → Future
Why does this kill the ability to color the button at all?  For example if I try:

select > input[type="button"] {
	background-color: #ff0;
	}

mozilla still renders the background-color as ButtonFace instead of yellow.
Updating QA contact.
QA Contact: ckritzer → bsharma
Summary: [FIX-html.css]<select size="1"> css rendering problem → [CBX][FIX-html.css]<select size="1"> css rendering problem
It now seems to work as weel as it is going to. makring works for me
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → WORKSFORME
verified on build 2001-08-14-trunk
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: