Skip to content


term-screen: avoid deprecated 'gtk_style_context_get_background_color'
Browse files Browse the repository at this point in the history
  • Loading branch information
sc0w committed Jun 27, 2018
1 parent 7708278 commit 078d0b1
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/terminal-screen.c
Expand Up @@ -1071,6 +1071,7 @@ update_color_scheme (TerminalScreen *screen)
const gchar *bg_image_file;
double bg_alpha = 1.0;
GdkRGBA fg, bg;
GdkRGBA *c;
guint n_colors;
GtkStyleContext *context;
GError *error = NULL;
Expand All @@ -1079,7 +1080,13 @@ update_color_scheme (TerminalScreen *screen)
gtk_style_context_save (context);
gtk_style_context_set_state (context, GTK_STATE_FLAG_NORMAL);
gtk_style_context_get_color (context, GTK_STATE_FLAG_NORMAL, &fg);
gtk_style_context_get_background_color (context, GTK_STATE_FLAG_NORMAL, &bg);

gtk_style_context_get (context, GTK_STATE_FLAG_NORMAL,
&c, NULL);
bg = *c;
gdk_rgba_free (c);

gtk_style_context_restore (context);

bold_rgba = NULL;
Expand Down

0 comments on commit 078d0b1

Please sign in to comment.