bgColor (bug #70352)

Rob Buis rwlbuis at xs4all.nl
Wed Feb 18 07:50:58 GMT 2004


Hi,

On Wed, Feb 18, 2004 at 08:28:11AM +0100, Stephan Kulow wrote:
> Am Dienstag 17 Februar 2004 21:36 schrieb rwlbuis at xs4all.nl:
> > Hi,
> >
> > I have looked at the problem with bug #70352. It boils
> > down to how to deal with bgColor="". It seems used as a way to "unset"
> > bgColor, so to get rid of the property. I have tried to reflect that
> > in my patch, which fixes this problem for the testcase.
> > But since I am no expert on this deprecated attribute, it may need more
> > discussing?
> 
> This was most likely introduced by another fix we did. In 3.1 the parser
> removed the attribute when it got a parsing error and that was fixed
> (#69182) so I'd say your fix is the right one. It's even possible that this

Great :)

> is not the only attribute with the problem.

Indeed, and also this property is not only used in 
HTMLtablePartElementImpl, so all occurences would need checking.
I looked at the code some more and noticed that in HTMLTableElementImpl
the following code is used :

case ATTR_BGCOLOR:
	if(!attr->value().isEmpty())

and, again, in HTMLTableElementImpl :

case ATTR_BGCOLOR:
	if(attr->val())

So I ask to the more khtml experienced guys (than me), is it safe to go
with the first approach with the isEmpty() check?
Cheers,

Rob.




More information about the kfm-devel mailing list