home-manager/gui: Use Monocraft font

This commit is contained in:
Jack O'Sullivan 2023-09-20 15:01:04 +01:00
parent af93a5c72e
commit c411e5dec9
2 changed files with 15 additions and 7 deletions

View File

@ -4,6 +4,12 @@ let
inherit (lib.my) mkBoolOpt'; inherit (lib.my) mkBoolOpt';
cfg = config.my.gui; cfg = config.my.gui;
font = {
package = pkgs.monocraft;
name = "Monocraft";
size = 10;
};
in in
{ {
options.my.gui = { options.my.gui = {
@ -16,6 +22,7 @@ in
{ {
home = { home = {
packages = with pkgs; [ packages = with pkgs; [
font.package
(nerdfonts.override { (nerdfonts.override {
fonts = [ "DroidSansMono" "SourceCodePro" ]; fonts = [ "DroidSansMono" "SourceCodePro" ];
}) })
@ -43,13 +50,13 @@ in
alacritty = { alacritty = {
enable = true; enable = true;
settings = { settings = {
font.normal.family = "SauceCodePro Nerd Font Mono"; font.normal.family = font.name;
}; };
}; };
kitty = { kitty = {
enable = true; enable = true;
font.name = "SauceCodePro Nerd Font Mono"; inherit font;
settings = { settings = {
background_opacity = "0.8"; background_opacity = "0.8";
tab_bar_edge = "top"; tab_bar_edge = "top";
@ -197,6 +204,7 @@ in
name = "Numix"; name = "Numix";
package = pkgs.numix-icon-theme; package = pkgs.numix-icon-theme;
}; };
font.name = font.name;
}; };
qt = { qt = {
enable = true; enable = true;
@ -251,10 +259,10 @@ in
}; };
}; };
waybar = import ./waybar.nix { inherit lib pkgs config; }; waybar = import ./waybar.nix { inherit lib pkgs config font; };
rofi = { rofi = {
enable = true; enable = true;
font = "SauceCodePro Nerd Font Mono 14"; font = "${font.name} ${toString font.size}";
plugins = with pkgs; [ plugins = with pkgs; [
rofi-calc rofi-calc
rofi-emoji rofi-emoji

View File

@ -1,4 +1,4 @@
{ lib, pkgs, config, ... }: { lib, pkgs, config, font, ... }:
let let
inherit (lib) mkIf mkDefault mkMerge mkForce; inherit (lib) mkIf mkDefault mkMerge mkForce;
@ -155,8 +155,8 @@ in
}; };
style = '' style = ''
* { * {
font-size: 14px; font-size: 12px;
font-family: SauceCodePro Nerd Font Mono; font-family: ${font.name};
/*font-family: monospace;*/ /*font-family: monospace;*/
} }