Fix the default background color reported for toplevel windows with GTK3
See #18811
This commit is contained in:
@@ -35,6 +35,7 @@
|
||||
|
||||
#include "wx/gtk/private.h"
|
||||
#include "wx/gtk/private/gtk3-compat.h"
|
||||
#include "wx/gtk/private/stylecontext.h"
|
||||
#include "wx/gtk/private/win_gtk.h"
|
||||
|
||||
#ifdef GDK_WINDOWING_X11
|
||||
@@ -1815,3 +1816,12 @@ bool wxTopLevelWindowGTK::CanSetTransparent()
|
||||
"Composite", &opcode, &event, &error);
|
||||
#endif
|
||||
}
|
||||
|
||||
wxVisualAttributes wxTopLevelWindowGTK::GetDefaultAttributes() const
|
||||
{
|
||||
wxVisualAttributes attrs(GetClassDefaultAttributes());
|
||||
#ifdef __WXGTK3__
|
||||
wxGtkStyleContext().AddWindow().Bg(attrs.colBg);
|
||||
#endif
|
||||
return attrs;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user