[patch] #69130: buttons, select etc is not always rendered correctly

Germain Garand germain at ebooksfrance.org
Tue Dec 9 09:24:20 GMT 2003


Le Mardi 09 Décembre 2003 08:33, Stephan Kulow a écrit :
> On Monday 08 December 2003 20:31, Dirk Mueller wrote:
> > On Sunday 07 December 2003 14:49, Germain Garand wrote:
> > > oh, I forgot about the special cases... it would probably be better as:
> > >
> > > +          if (strcmp(widget()->name(), "__khtml"))
> > >                 widget()->setEraseColor(backgroundColor );
> >
> > Yes, I would prefer that (even over coolo's patch).
>
> I'm confused. That wouldn't set the erase color for line edits, no?

I've digged a bit more into that ; the real problem is that
setEraseColor() isn't compatible with setBackgroundMode( Qt::NoBackground ) 
which is the case for proxied widgets...
setEraseColor will change the background mode to FixedColor.

Now, the call to setEraseColor() was needed because the code in copyWidget 
uses QPixmap::fill() to fill the Line Edits background (yes there's already a 
special case there), and QPixmap::fill() eventually retrieves the background 
color of the widget with eraseColor()...

So attached is a proposed generic solution.

Germain

>
> Greetings, Stephan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: render_replaced.cpp.diff
Type: text/x-diff
Size: 1356 bytes
Desc: not available
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20031209/af06e6cb/attachment.diff>


More information about the kfm-devel mailing list