{pkgs, config, lib, ... }: with lib; let xorg = (elem "xorg" config.sys.graphics.desktopProtocols); wayland = (elem "wayland" config.sys.graphics.desktopProtocols); desktopMode = xorg || wayland; in { config= mkIf desktopMode { fonts = { fontconfig.enable = true; fonts = with pkgs; [ noto-fonts-emoji dejavu_fonts source-code-pro source-sans-pro source-serif-pro ]; fontconfig.defaultFonts = { monospace = [ "Source Code Pro" ]; }; }; }; }