Re: no background-color but i have

On Nov 20, 2006, at 11:47 AM, Jukka K. Korpela wrote:

>
> On Mon, 20 Nov 2006, Kosa Gergely wrote:
>
>> the validator says
>>
>> Line : 151 (Level : 1) You have no background-color with your  
>> color : img#logo
>>
>> but I have, it is transparent, what is the problem than?
>
> No, transparent is not a color. It is a keyword indicating the  
> absence of any color, i.e. the background of the enclosing element  
> shines through. And that is the problem: that background might be  
> set (e.g., by a user style sheet) to anything, including the color  
> of your text, or something close to it.
>
> -- 
> Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/

I'd suggest rewording the message so it's clearer (no pun  
intended :-).  In English, there is a "background color".  In CSS,  
there is a "background-color".  If you have a background-color line  
in your CSS file, you have a "background-color" but perhaps not a  
"background color".  If there really is a special warning message  
just for this one value "transparent", it would also be helpful to  
repeat "transparent" in the warning, something like:

The background-color value "transparent" might not provide sufficient  
contrast with your color: ...

John

Received on Monday, 20 November 2006 21:23:25 UTC