Commit 5ddbfecd authored by Sean Davis's avatar Sean Davis

Improve contrast in weather report, similar to GTK2 + Adwaita (bug #15806)

parent ff0c3ec9
...@@ -947,13 +947,17 @@ make_forecast(plugin_data *data) ...@@ -947,13 +947,17 @@ make_forecast(plugin_data *data)
GtkCssProvider *provider = gtk_css_provider_new (); GtkCssProvider *provider = gtk_css_provider_new ();
gchar *css_string; gchar *css_string;
css_string = g_strdup (".forecast-cell.lightbg { background-color: rgba(0, 0, 0, 0.2); }" GtkStyleContext *ctx;
".forecast-cell.darkbg { background-color: rgba(0, 0, 0, 0.4); }");
css_string = g_strdup (".forecast-cell.lightbg { background-color: rgba(0, 0, 0, 0.05); }"
".forecast-cell.darkbg { background-color: rgba(0, 0, 0, 0.6); }");
gtk_css_provider_load_from_data (provider, css_string, -1, NULL); gtk_css_provider_load_from_data (provider, css_string, -1, NULL);
gtk_style_context_add_provider_for_screen (screen, GTK_STYLE_PROVIDER (provider), GTK_STYLE_PROVIDER_PRIORITY_APPLICATION); gtk_style_context_add_provider_for_screen (screen, GTK_STYLE_PROVIDER (provider), GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
grid = gtk_grid_new (); grid = gtk_grid_new ();
ctx = gtk_widget_get_style_context (GTK_WIDGET (grid));
gtk_style_context_add_class (ctx, "background");
gtk_grid_set_row_spacing(GTK_GRID (grid), 0); gtk_grid_set_row_spacing(GTK_GRID (grid), 0);
gtk_grid_set_column_spacing(GTK_GRID (grid), 0); gtk_grid_set_column_spacing(GTK_GRID (grid), 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment