From f3aed988c27ca4a37a5f5102c18012c3983a7191 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Sat, 20 Jun 2009 21:30:57 -0700 Subject: [PATCH] output: Use "base" color for background in GUI output window. The "base" color in GtkStyle is used as the background color for GTK+ widgets that display editable text, e.g. GtkEntry. That's what we're aiming for, eventually, with the PSPP GUI output, and the default white "base" color looks better than the default gray background color, so use it. --- src/ui/gui/psppire-output-window.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ui/gui/psppire-output-window.c b/src/ui/gui/psppire-output-window.c index f2f0ca2d..06692c2a 100644 --- a/src/ui/gui/psppire-output-window.c +++ b/src/ui/gui/psppire-output-window.c @@ -165,6 +165,8 @@ psppire_output_submit (struct outp_driver *this, struct som_entity *entity) entity->class->area (rendering, &tw, &th); drawing_area = gtk_drawing_area_new (); + gtk_widget_modify_bg (GTK_WIDGET (drawing_area), GTK_STATE_NORMAL, + >k_widget_get_style (drawing_area)->base[GTK_STATE_NORMAL]); g_object_set_data (G_OBJECT (drawing_area), "entity", xmemdup (entity, sizeof *entity)); gtk_widget_set_size_request (drawing_area, tw / 1024, th / 1024); @@ -249,6 +251,9 @@ psppire_output_window_init (PsppireOutputWindow *window) window->output = GTK_LAYOUT (get_widget_assert (xml, "output")); window->y = 0; + gtk_widget_modify_bg (GTK_WIDGET (window->output), GTK_STATE_NORMAL, + >k_widget_get_style (GTK_WIDGET (window->output))->base[GTK_STATE_NORMAL]); + connect_help (xml); g_signal_connect (window, -- 2.30.2