diff --git a/modules/xconfig.nix b/modules/xconfig.nix index 50b8cc2..906268a 100644 --- a/modules/xconfig.nix +++ b/modules/xconfig.nix @@ -44,15 +44,29 @@ in { config = mkIf cfg.enable { + services.libinput = { + mouse = { + accelProfile = cfg.mouse.accelProfile; + middleEmulation = false; + }; + touchpad = mkIf cfg.touchpad.enableProperConfig { + tapping = false; + disableWhileTyping = true; + accelProfile = cfg.touchpad.accelProfile; + }; + }; + services.xserver = { - extraLayouts.bqn = mkIf cfg.bqn.enable { - description = "BQN layout"; - languages = [ "bqn" ]; - symbolsFile = ./misc/bqn; + xkb = { + options = mkIf cfg.bqn.enable "grp:switch"; + layout = (if cfg.bqn.enable then "us,bqn" else "us"); + extraLayouts.bqn = mkIf cfg.bqn.enable { + description = "BQN layout"; + languages = [ "bqn" ]; + symbolsFile = ./misc/bqn; + }; }; - layout = (if cfg.bqn.enable then "us,bqn" else "us"); - xkbOptions = mkIf cfg.bqn.enable "grp:switch"; enable = true; autoRepeatDelay = 200; @@ -66,17 +80,6 @@ in { greeters.gtk.enable = true; background = cfg.lightdm.background; }; - libinput = { - mouse = { - accelProfile = cfg.mouse.accelProfile; - middleEmulation = false; - }; - touchpad = mkIf cfg.touchpad.enableProperConfig { - tapping = false; - disableWhileTyping = true; - accelProfile = cfg.touchpad.accelProfile; - }; - }; }; }; }