diff --git a/global/default.nix b/global/default.nix index 02fa6b4..75c303d 100755 --- a/global/default.nix +++ b/global/default.nix @@ -234,6 +234,14 @@ trilium-desktop ]; + fonts.packages = with pkgs; [ + twitter-color-emoji + ]; + + fonts.fontconfig.defaultFonts = { + emoji = [ "Twitter Color Emoji" ]; + }; + services.usbmuxd = { enable = true; package = pkgs.usbmuxd2; diff --git a/modules/sway/default.nix b/modules/sway/default.nix index 21adeff..0e6b6f4 100644 --- a/modules/sway/default.nix +++ b/modules/sway/default.nix @@ -5,6 +5,23 @@ inputs, ... }: +let + configure-gtk = pkgs.writeTextFile { + name = "configure-gtk"; + destination = "/bin/configure-gtk"; + executable = true; + text = + let + schema = pkgs.gsettings-desktop-schemas; + datadir = "${schema}/share/gsettings-schemas/${schema.name}"; + in + '' + export XDG_DATA_DIRS=${datadir}:$XDG_DATA_DIRS + gnome_schema=org.gnome.desktop.interface + gsettings set $gnome_schema gtk-theme 'Dracula' + ''; + }; +in { environment.systemPackages = with pkgs; [ wl-clipboard # Copy/Paste functionality. @@ -14,10 +31,20 @@ # Enables Gnome Keyring to store secrets for applications. services.gnome.gnome-keyring.enable = true; + xdg.portal = { + enable = true; + extraPortals = [ + pkgs.xdg-desktop-portal-gtk + pkgs.xdg-desktop-portal-wlr + ]; + }; + + security.polkit.enable = true; + # Enable Sway. programs.sway = { enable = true; - wrapperFeatures.gtk = true; + wrapperFeatures.gtk = false; extraPackages = [ pkgs.foot pkgs.swayidle @@ -32,7 +59,8 @@ pkgs.swaybg pkgs.pulseaudioFull pkgs.waybar - pkgs.twitter-color-emoji + pkgs.dracula-theme # gtk theme + configure-gtk ]; }; diff --git a/modules/sway/waybar.css b/modules/sway/waybar.css index c9bcd8b..327775a 100644 --- a/modules/sway/waybar.css +++ b/modules/sway/waybar.css @@ -1,10 +1,9 @@ * { - /* Prioritize Twemoji for icons, fallback to sans-serif for text */ - font-family: "Twitter Color Emoji", sans-serif; - font-size: 14px; + /* `otf-font-awesome` is required to be installed for icons */ + font-family: Roboto, Helvetica, Arial, sans-serif; + font-size: 13px; } - window#waybar { background-color: rgba(43, 48, 59, 0.5); border-bottom: 3px solid rgba(100, 114, 125, 0.5);