After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 680034 - GtkViewport should not define background color
GtkViewport should not define background color
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
3.4.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2012-07-16 16:42 UTC by Tobias Wolf
Modified: 2017-08-25 11:13 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Screenshot (23.62 KB, image/png)
2012-07-16 16:42 UTC, Tobias Wolf
Details
test.c (34.29 KB, text/plain)
2012-07-25 12:32 UTC, Milan Crha
Details

Description Tobias Wolf 2012-07-16 16:42:27 UTC
Created attachment 218932 [details]
Screenshot

I cannot decide if this is a real glitch or not. But it looks unpolished.
Comment 1 Cosimo Cecchi 2012-07-17 14:46:31 UTC
I believe this looks a bit weird only because that scrolled window has no border.
It should use something != GTK_SHADOW_NONE to get a border, and then the different background would have a reason for being different.
Comment 2 Milan Crha 2012-07-18 08:13:16 UTC
I would prefer to have other background on scrolled window from Gtk+/Theme, because it looks weird regardless theme or border. The previous drawing used to be that the border was the same as border of the window. Currently it seems like the border is same as the application window (my adwaita draws the background as white, not gray like border of the rest of the window - and it looks horrible on many places - like in Edit->Message Filters->Edit).
Comment 3 Milan Crha 2012-07-18 08:21:53 UTC
(In reply to comment #2)
> like the border is same as the application window (my adwaita draws the

I meant as the application content, like GtkEntry, GtkTextView and so on.
Comment 4 Milan Crha 2012-07-25 12:32:56 UTC
Created attachment 219625 [details]
test.c

This is a test program showing the issue. The only useful code is in the main(), the rest is just a copy of GtkViewport which uses different class name, thus it's not influenced by standard CSS files. I would be happy to override background color either by gtk_widget_override_background_color() or by removing the GtkViewport from the GtkWidgetPath on the style, but changing these does nothing (the background on the label, the path on both standard GtkViewport and the label).

Check for 'show_broken' at the end of the file. Changing its value to 0 will show that GtkViewport defines the "strange" background color. It's regression from the previous gtk versions, if I recall correctly.
Comment 5 Daniel Boles 2017-08-25 11:13:55 UTC
I think this was resolved by commit 09835b4c3987d67aafe7ae4ded039beb175121c9