[metacity] ui: disable scaling support in GTK+



commit a1b96fd6a8ff7187297f6ae2051b33cdb176c5d4
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 4014036..4670507 100644
--- a/src/ui/ui.c
+++ b/src/ui/ui.c
@@ -75,6 +75,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]