# Hyprland under uwsm, the greetd login screen, audio, Bluetooth, fonts and the # system side of theming. { config, lib, pkgs, ... }: let greetdFiles = ../../config/greetd; in { programs.hyprland = { enable = true; # uwsm starts Hyprland as a systemd unit and brings up # graphical-session.target, which the user services in # modules/home/services.nix hang off. withUWSM = true; }; programs.hyprlock.enable = true; xdg.portal = { enable = true; # File pickers and settings for GTK apps; screen sharing comes from # xdg-desktop-portal-hyprland, which programs.hyprland adds. extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; }; # --- Login screen ------------------------------------------------------------- # gtkgreet in a small Hyprland of its own, blurred over the wallpaper. Same # files as /etc/greetd on CachyOS; see config/greetd. services.greetd = { enable = true; settings = { terminal.vt = 1; default_session = { command = "${config.programs.hyprland.package}/bin/start-hyprland -- --config /etc/greetd/hyprland.lua"; user = "greeter"; }; }; }; environment.etc = { "greetd/hyprland.lua".source = "${greetdFiles}/hyprland.lua"; "greetd/hyprpaper.conf".source = "${greetdFiles}/hyprpaper.conf"; "greetd/style.css".source = "${greetdFiles}/style.css"; "greetd/session.sh".source = "${greetdFiles}/session.sh"; "greetd/wallpapers/wallpaper.jpg".source = ../../config/hypr/wallpaper.jpg; }; # The greeter user has no settings of its own; these system-wide GSettings # defaults give gtkgreet the desktop's cursor. They replace # 99_greeter-cursor.gschema.override from CachyOS. programs.dconf = { enable = true; profiles.user.databases = [ { settings."org/gnome/desktop/interface" = { cursor-theme = "BreezeX-Black"; cursor-size = lib.gvariant.mkInt32 28; color-scheme = "prefer-dark"; }; } ]; }; # --- Audio, Bluetooth, devices -------------------------------------------------- services.pipewire = { enable = true; alsa.enable = true; alsa.support32Bit = true; pulse.enable = true; jack.enable = true; }; services.pulseaudio.enable = false; hardware.bluetooth = { enable = true; powerOnBoot = true; }; services.blueman.enable = true; services.upower.enable = true; services.udisks2.enable = true; services.gvfs.enable = true; security.polkit.enable = true; # Secret Service (what Electron apps and libsecret store passwords in) from # KWallet's ksecretd, started on demand over D-Bus, as on CachyOS. Not GNOME # Keyring: it would claim the same D-Bus name. services.dbus.packages = [ pkgs.kdePackages.kwallet ]; # Battery of the Logitech mouse in the control centre (mouse-battery.sh). hardware.logitech.wireless.enable = true; # --- Fonts ------------------------------------------------------------------- # The fonts installed on CachyOS. kitty.conf asks for JetBrains Mono, which # was never installed there, so kitty has been using Noto Sans Mono; add # nerd-fonts.jetbrains-mono here to get the font the config names. fonts.packages = with pkgs; [ noto-fonts noto-fonts-cjk-sans noto-fonts-color-emoji nerd-fonts.noto nerd-fonts.meslo-lg nerd-fonts.fantasque-sans-mono dejavu_fonts liberation_ttf ttf-bitstream-vera open-sans cantarell-fonts adwaita-fonts font-awesome wqy_zenhei ]; # --- Theming (system side) ------------------------------------------------------ # Qt apps use qt6ct + Kvantum (QT_QPA_PLATFORMTHEME is set in hyprland.lua). qt = { enable = true; platformTheme = "qt5ct"; style = "kvantum"; }; environment.systemPackages = with pkgs; [ # The greeter runs these from /etc/greetd/hyprland.lua. gtkgreet hyprpaper kitty procps breezex-cursor papirus-icon-theme kdePackages.breeze-icons gnome-themes-extra adwaita-icon-theme kdePackages.qtstyleplugin-kvantum libsForQt5.qtstyleplugin-kvantum qt6Packages.qt6ct ]; }