From f2f6bd0ff967ce03d8b5098e67fe6bc7eb36a47c Mon Sep 17 00:00:00 2001 From: Andre Date: Sat, 14 Dec 2024 02:11:38 -0500 Subject: [PATCH] Khanda: enable XWayland scaling for Obsidian --- modules/nixos/ui/desktops/gnome/default.nix | 1 - systems/x86_64-linux/Khanda/default.nix | 10 ++++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/modules/nixos/ui/desktops/gnome/default.nix b/modules/nixos/ui/desktops/gnome/default.nix index 51bf97d..619ce53 100644 --- a/modules/nixos/ui/desktops/gnome/default.nix +++ b/modules/nixos/ui/desktops/gnome/default.nix @@ -1,6 +1,5 @@ # Enables the Gnome desktop environment. { - inputs, pkgs, config, lib, diff --git a/systems/x86_64-linux/Khanda/default.nix b/systems/x86_64-linux/Khanda/default.nix index ff3c433..3d310a6 100644 --- a/systems/x86_64-linux/Khanda/default.nix +++ b/systems/x86_64-linux/Khanda/default.nix @@ -1,5 +1,6 @@ { config, + lib, options, namespace, ... @@ -16,6 +17,15 @@ in system.stateVersion = stateVersion; networking.hostName = hostName; + # Enable XWayland native scaling just for Khanda. + # This is a workaround to get the Surface Pen working in Obsidian + services.xserver.desktopManager.gnome.extraGSettingsOverrides = lib.mkForce '' + [org.gnome.mutter] + experimental-features = [ 'scale-monitor-framebuffer', 'xwayland-native-scaling', 'variable-refresh-rate' ] + [org.gnome.shell] + disable-extension-version-validation = true + ''; + ###*** Configure your system below this line. ***### # Configure the system. ${namespace} = {