Re: Patch to fix togglebuttons popping up



Havoc Pennington <hp@redhat.com> writes:

> Tim Janik <timj@gtk.org> writes: 
> > i'm sorry, i still don't understand. first, prelight changes the background
> > color, not the shadow, so how's prelighting making the button "pop out"?
> > second, i applied the patch and get exactly the same behaviour as before
> > (i couldn't tell how the patch would change the prelighting anyways),
> > i.e. an active toggle button with mouse entered is drawn with a prelight
> > background and a SHADOW_IN frame.
> > 
> 
> I didn't actually look at the patch, I've just seen the problem myself
> - if you run testgtk and look at the toggle button test, it sure looks
> to me like the prelight pops the buttons out. If I look at the code,
> it looks like that's a SHADOW_IN frame getting drawn, but the result
> doesn't look like it's pressed in, it looks popped out.

Togglebuttons uses the expose method inherited from button. This calls
gtk_button_paint which is different from gtk_toggle_button_paint. The
patch make togglebutton not inherit their expose methods. Instead they
paint themselves.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]