GNOME Bugzilla – Bug 569635
fontchooser should reload list of families/styles on theme change
Last modified: 2009-02-01 05:26:59 UTC
That's for online font installation to work better.
Does a font installation incur a theme change ?
(In reply to comment #1) > Does a font installation incur a theme change ? That's the signal gtk sends to widgets, isn't it? case PROP_FONTCONFIG_TIMESTAMP: if (settings_update_fontconfig (settings)) gtk_rc_reset_styles (GTK_SETTINGS (object));
Ah, yes.
Can you provide a patch for this, Behdad ?
Created attachment 127677 [details] [review] Patch Works like a charm.
Should just use a style_set class handler, instead of connecting to the signal (compare e.g. gtkimage.c). Other than that, looks good.
Doh. Thought there should be one. Didn't really check. Just copied from what vte's doing. BTW, you know how hard this stuff is to find in the docs? :)
2009-02-01 Behdad Esfahbod <behdad@gnome.org> Bug 569635 – fontchooser should reload list of families/styles on theme change * gtk/gtkfontsel.c (gtk_font_selection_class_init), (gtk_font_selection_init), (gtk_font_selection_finalize), (gtk_font_selection_ref_family), (gtk_font_selection_ref_face), (gtk_font_selection_reload_fonts), (gtk_font_selection_screen_changed), (gtk_font_selection_style_set), (gtk_font_selection_scroll_to_selection), (gtk_font_selection_scroll_on_map), (gtk_font_selection_select_font), (gtk_font_selection_show_available_fonts), (gtk_font_selection_show_available_styles), (gtk_font_selection_select_style), (gtk_font_selection_select_font_desc), (gtk_font_selection_set_font_name): Reload Pango families and faces in style_set. Installing/uninstalling fonts shows up immediately in an open font chooser now.