[metacity/gnome-3-18] ui: disable scaling support in GTK+



commit d06393b4952333883d66c2b0d570eedc19e8e7a0
Author: Alexander Larsson <alexl redhat com>
Date:   Tue Aug 20 14:03:42 2013 +0200

    ui: disable scaling support in GTK+
    
    We can't really support the GTK+ automatic scaling, as to much
    code relies on the GdkWindow and XWindow sizes, etc to match.
    In order to keep working we just disable the scaling, meaning
    we will pick up the larger fonts, but nothing else. Its not
    ideal but it works for now.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=706388

 src/ui/ui.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/ui/ui.c b/src/ui/ui.c
index c647c90..3f8b53b 100644
--- a/src/ui/ui.c
+++ b/src/ui/ui.c
@@ -65,6 +65,11 @@ meta_ui_init (int *argc, char ***argv)
 
   if (!gtk_init_check (argc, argv))
     meta_fatal ("Unable to open X display %s\n", XDisplayName (NULL));
+
+  /* We need to be able to fully trust that the window and monitor sizes
+   * that GDK reports corresponds to the X ones, so we disable the automatic
+   * scale handling */
+  gdk_x11_display_set_window_scale (gdk_display_get_default (), 1);
 }
 
 Display*


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]