GNOME Bugzilla – Bug 330840
Combo boxes popup list has white background after theme change
Last modified: 2006-12-20 21:06:57 UTC
Opening a popup list after a theme change will display a list with white background. The list must be accessed at least onece before theme changing to see this effect. GTK version tested is 2.8.10. Clearlooks and Crux themes used (but same effect with all other themes tested). Steps to reproduce: 1. run gtk-demo and open "Combo boxes" window 2. open the popup list of one of the combo boxes 3. select a different gnome theme and then reselect the old one 4. reopen the popup list of the combo box
Created attachment 59156 [details] white.png On the left before theme change and on the right after theme change.
cannot reproduce with gnome 2.13 can you check with a later release, please?
Upgraded to gtk 2.8.12 (gtk only), same effect.
doesn't happen for me here. Can you tell me which themes you switch between ?
Matthias, switching from Clearlooks to any other theme (tested Mist, Crux and Gorilla) and then back to Clearlooks ends with a white background in popped up combo box list. Using a dark colored Clearlooks may help seeing the effect. I have noted that only Clearlooks based themes are affected, so it is highly likely a theme bug, not gtk. I will try an updated Clearlooks version as soon as possible.
Tested gtk-engines 2.7.4, but behaviour is still the same.
I don't think we are treating that combo box menu special in any way, style-wise. Do you see the same problem with other menus ?
Matthias, with GtkComboBox and GtkFileChooserButton with GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER opening mode only, no other widgets. I don't really know what to do. It seems I'm the only one to see this behaviour.
I am able to reproduce this. It only happens if the GtkMenu had been opened (ie. is realized) when the theme changes. The menu usually sets bg[NORMAL] as the background color. However for some reason the background color is set to base[NORMAL] of the GtkCellView widget when the style is changed.
It looks to me like the gtk_cell_view_style_set function needs to be removed. It sets the background of the window to base[NORMAL] when the theme is changed, but nothing is done when realizing the widget.
Created attachment 61793 [details] [review] patch to fix this bug (removes gtk_cell_view_style_set)
Hmm, I had considered that. Problem is that I don't remember why the style set implementation is there in the first place. I have a feeling it is to make cellviews inside menuitems work correctly.
Thanks Benjamin. I tested the patch and fixed the problem. I can see no other visual problems with menus or comboboxes. Matthias, if you have a specific test I can perform, let me know.
Fix was committed for bug 359581