From cac56f5d00665b854779708dd7d0c744f89db490 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Charlotte=20=F0=9F=A6=9D=20Delenk?= Date: Wed, 22 Jun 2022 16:13:11 +0100 Subject: [PATCH] add a sway background --- config/programs/sway.nix | 22 ++++++++++++++++++++++ config/workarounds/default.nix | 2 +- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/config/programs/sway.nix b/config/programs/sway.nix index a0c8a6d7..cabd6abc 100644 --- a/config/programs/sway.nix +++ b/config/programs/sway.nix @@ -38,6 +38,23 @@ ${pkgs.sway-contrib.grimshot}/bin/grimshot "$@" ${pkgs.sway}/bin/swaymsg mode default ''; + bg-full-res = "${pkgs.lotte-art}/2022-06-21-sammythetanuki-lotteplushpride.jxl"; + bg-1440p = pkgs.stdenvNoCC { + name = "wayland-background-1440p.png"; + nativeBuildInputs = [pkgs.imagemagick]; + buildPhase = '' + convert ${bg-full-res} -resize 2560x1440 $out + ''; + installPhase = "true"; + }; + bg-1080p = pkgs.stdenvNoCC { + name = "wayland-background-1080p.png"; + nativeBuildInputs = [pkgs.imagemagick]; + buildPhase = '' + convert ${bg-full-res} -resize 1920x1080 $out + ''; + installPhase = "true"; + }; in { imports = [ ./wl-clipboard.nix @@ -61,16 +78,21 @@ in { }; }; output = { + "eDP-1" = { + bg = "${bg-1080p} fill"; + }; "DP-1" = { mode = "2560x1440@74.971Hz"; position = "0 0"; subpixel = "rgb"; adaptive_sync = "on"; + bg = "${bg-1440p} fill"; }; "HDMI-A-1" = { mode = "1920x1080@60Hz"; position = "2560 0"; subpixel = "rgb"; + bg = "${bg-1080p} fill"; }; }; keybindings = let diff --git a/config/workarounds/default.nix b/config/workarounds/default.nix index 722e2292..912e2f35 100644 --- a/config/workarounds/default.nix +++ b/config/workarounds/default.nix @@ -65,7 +65,7 @@ in { */ inherit (noto-variable) noto-fonts-cjk; inherit (go116) buildGo116Module; - inherit (nix-packages.packages.${system}) plover plover-plugins-manager regenpfeifer plover-regenpfeifer; + inherit (nix-packages.packages.${system}) plover plover-plugins-manager regenpfeifer plover-regenpfeifer lotte-art; kitty = prev.kitty.overrideAttrs (old: { patches = old.patches