diff options
author | Victor Kareh <[email protected]> | 2018-03-23 23:58:48 -0400 |
---|---|---|
committer | Martin Wimpress <[email protected]> | 2018-03-26 21:27:43 +0100 |
commit | f45d299364bbadf8ff5f11307bac711d4f42c2af (patch) | |
tree | 269a002ccea14cdd9e4c9283ecfed0061e2d5c02 | |
parent | 03029b3d597b7b4962f4ad9398a36128958bba63 (diff) | |
download | marco-f45d299364bbadf8ff5f11307bac711d4f42c2af.tar.bz2 marco-f45d299364bbadf8ff5f11307bac711d4f42c2af.tar.xz |
Scale cursor size for HiDPI
-rw-r--r-- | src/core/prefs.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/core/prefs.c b/src/core/prefs.c index 021ad874..e376089c 100644 --- a/src/core/prefs.c +++ b/src/core/prefs.c @@ -27,6 +27,7 @@ #include "prefs.h" #include "ui.h" #include "util.h" +#include <gdk/gdk.h> #include <gio/gio.h> #include <string.h> #include <stdlib.h> @@ -1097,7 +1098,10 @@ meta_prefs_get_cursor_theme (void) int meta_prefs_get_cursor_size (void) { - return cursor_size; + GdkWindow *window = gdk_get_default_root_window (); + gint scale = gdk_window_get_scale_factor (window); + + return cursor_size * scale; } gboolean |