summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2018-08-06 02:27:36 +0200
committerVictor Kareh <[email protected]>2018-08-13 16:37:00 -0400
commitca00615b510549a4abfe44f7b1f97485e1e9f804 (patch)
tree73ef41173e03a285fb37ae0f8f4da8d05862f12a
parenteb7a39bd311d89bf0e798f9d4b2cda80596e9217 (diff)
downloadpluma-ca00615b510549a4abfe44f7b1f97485e1e9f804.tar.bz2
pluma-ca00615b510549a4abfe44f7b1f97485e1e9f804.tar.xz
pluma-view: Fix bold and italic fonts in menus
-rw-r--r--pluma/pluma-view.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/pluma/pluma-view.c b/pluma/pluma-view.c
index d488777e..c822ebd3 100644
--- a/pluma/pluma-view.c
+++ b/pluma/pluma-view.c
@@ -667,15 +667,15 @@ static PangoFontDescription* get_system_font (void)
}
static void
-contextmenu_font_changed_cb (GSettings *settings,
- gchar *key,
- gpointer user_data)
+system_font_changed_cb (GSettings *settings,
+ gchar *key,
+ gpointer user_data)
{
PangoFontDescription *sys_font_desc = NULL;
sys_font_desc = get_system_font ();
if (sys_font_desc)
{
- pluma_override_font (".context-menu", NULL, sys_font_desc);
+ pluma_override_font ("label", NULL, sys_font_desc);
pango_font_description_free (sys_font_desc);
}
}
@@ -714,9 +714,9 @@ pluma_override_font (const gchar *item,
prov_str = gtk_css_provider_to_string (provider);
- if (g_str_has_prefix (prov_str, "textview") && g_str_has_prefix (item, ".context-menu"))
+ if (g_str_has_prefix (prov_str, "textview") && g_str_has_prefix (item, "label"))
{
- if (strstr (prov_str, ".context-menu"))
+ if (strstr (prov_str, "label"))
{
g_strdelimit (prov_str, "}", '\0');
gchar *prov_new_str = g_strdup_printf ("%s}", prov_str);
@@ -737,7 +737,7 @@ pluma_override_font (const gchar *item,
settings = g_settings_new ("org.mate.interface");
g_signal_connect (settings,
"changed::" "font-name",
- G_CALLBACK (contextmenu_font_changed_cb), NULL);
+ G_CALLBACK (system_font_changed_cb), NULL);
gtk_style_context_add_provider_for_screen (gtk_widget_get_screen (widget),
GTK_STYLE_PROVIDER (provider),
@@ -795,7 +795,7 @@ pluma_view_set_font (PlumaView *view,
sys_font_desc = get_system_font ();
if (sys_font_desc) {
- pluma_override_font (".context-menu", GTK_WIDGET (view), sys_font_desc);
+ pluma_override_font ("label", GTK_WIDGET (view), sys_font_desc);
pango_font_description_free (sys_font_desc);
}