Provide scale factor to wxGtkStyleContext where it might matter.
This commit is contained in:
parent
e13a2cfd03
commit
dc0cf732a2
@ -790,7 +790,8 @@ wxFont wxSystemSettingsNative::GetFont( wxSystemFont index )
|
||||
g_signal_connect(gtk_settings_get_default(), "notify::gtk-font-name",
|
||||
G_CALLBACK(notify_gtk_font_name), NULL);
|
||||
}
|
||||
wxGtkStyleContext sc;
|
||||
ContainerWidget();
|
||||
wxGtkStyleContext sc(gtk_widget_get_scale_factor(gs_tlw_parent));
|
||||
sc.AddButton().AddLabel();
|
||||
gtk_style_context_get(sc, GTK_STATE_FLAG_NORMAL,
|
||||
GTK_STYLE_PROPERTY_FONT, &info.description, NULL);
|
||||
@ -874,7 +875,7 @@ static int GetScrollbarWidth()
|
||||
if (wx_is_at_least_gtk3(20))
|
||||
{
|
||||
GtkBorder border;
|
||||
wxGtkStyleContext sc;
|
||||
wxGtkStyleContext sc(gtk_widget_get_scale_factor(ScrollBarWidget()));
|
||||
sc.Add(GTK_TYPE_SCROLLBAR, "scrollbar", "scrollbar", "vertical", "right", NULL);
|
||||
|
||||
gtk_style_context_get_border(sc, GTK_STATE_FLAG_NORMAL, &border);
|
||||
|
Loading…
Reference in New Issue
Block a user