diff --git a/home/modules/gnome/default.nix b/home/modules/gnome/default.nix index d75a11c4..ff4770a0 100644 --- a/home/modules/gnome/default.nix +++ b/home/modules/gnome/default.nix @@ -327,7 +327,7 @@ in { "org/gnome/TextEditor" = { auto-indent = true; - custom-font = "Victor Mono Semi-Bold 11"; + custom-font = "JetBrainsMono Nerd Font Mono 11"; highlight-current-line = true; indent-style = "space"; show-gird = false; diff --git a/home/modules/kitty/default.nix b/home/modules/kitty/default.nix index cc7f928f..421ac32e 100644 --- a/home/modules/kitty/default.nix +++ b/home/modules/kitty/default.nix @@ -18,8 +18,8 @@ in { enable = true; font = { - package = pkgs.victor-mono; - name = "Victor Mono SemiBold"; + # package = pkgs.victor-mono; + name = "JetBrainsMono Nerd Font Mono"; size = 12; }; diff --git a/home/modules/neovim/default.nix b/home/modules/neovim/default.nix index 4eed1ba0..a60cf8fc 100644 --- a/home/modules/neovim/default.nix +++ b/home/modules/neovim/default.nix @@ -40,8 +40,8 @@ in { set undofile set undodir=~/.vim/undo set hidden - set printfont=Victor\ Mono\ SemiBold:h10 - set guifont=Victor\ Mono\ SemiBold:h12 + set printfont=JetBrainsMono\ Nerd\ Font\ Mono:h10 + set guifont=JetBrainsMono\ Nerd\ Font\ Mono:h12 let printencoding='utf-8' set encoding=utf-8 ''; diff --git a/system/default.nix b/system/default.nix index 4194a7d2..a7daa187 100644 --- a/system/default.nix +++ b/system/default.nix @@ -316,50 +316,16 @@ }; # See https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types - xdg.mime = { + xdg.mime = rec { enable = true; removedAssociations = { "application/pdf" = "chromium-browser.desktop"; }; - # TODO: This stuff depends on the used desktop...should I use a complementary system module for each DE? - addedAssociations = { - "application/pdf" = "org.pwmt.zathura.desktop"; - "application/x-sh" = "Helix.desktop"; - "application/xhtml+xml" = "Helix.desktop"; - "application/xml" = "Helix.desktop"; - - "image/bmp" = "imv.desktop"; - "image/jpeg" = "imv.desktop"; - "image/png" = "imv.desktop"; - "image/svg+xml" = "imv.desktop"; - "image/tiff" = "imv.desktop"; - "image/webp" = "imv.desktop"; - - "video/mp2t" = "mpv.desktop"; - "video/mp4" = "mpv.desktop"; - "video/mpeg" = "mpv.desktop"; - "video/ogg" = "mpv.desktop"; - "video/webm" = "mpv.desktop"; - "video/x-msvideo" = "mpv.desktop"; - "video/x-ms-wmv" = "mpv.desktop"; - - "text/css" = "Helix.desktop"; - "text/csv" = "Helix.desktop"; - "text/javascript" = "Helix.desktop"; - "text/json" = "Helix.desktop"; - "text/plain" = "Helix.desktop"; - "text/xml" = "Helix.desktop"; - - # "audio/mpeg" = "moc.desktop"; - # "audio/ogg" = "moc.desktop"; - # "audio/opus" = "moc.desktop"; - # "audio/wav" = "moc.desktop"; - # "audio/webm" = "moc.desktop"; - }; - defaultApplications = { + "inode/directory" = "nnn.desktop"; + "application/pdf" = "org.pwmt.zathura.desktop"; "application/x-sh" = "Helix.desktop"; "application/xhtml+xml" = "Helix.desktop"; @@ -376,7 +342,9 @@ "video/mp4" = "mpv.desktop"; "video/mpeg" = "mpv.desktop"; "video/ogg" = "mpv.desktop"; + "video/quicktime" = "mpv.desktop"; "video/webm" = "mpv.desktop"; + "video/x-matroska" = "mpv.desktop"; "video/x-msvideo" = "mpv.desktop"; "video/x-ms-wmv" = "mpv.desktop"; @@ -393,6 +361,8 @@ # "audio/wav" = "moc.desktop"; # "audio/webm" = "moc.desktop"; }; + + addedAssociations = defaultApplications; }; # Enable sound with pipewire. @@ -416,49 +386,28 @@ # Font packages go here # NOTE: Don't do this with HomeManager as I need the fonts in the fontdir for flatpak apps fonts = with pkgs; [ - # Mono fonts - victor-mono - jetbrains-mono - source-code-pro - (pkgs.nerdfonts.override {fonts = ["VictorMono"];}) - font-awesome - - # Chinese fonts - source-han-mono - source-han-sans - source-han-serif - noto-fonts-cjk-sans - noto-fonts-cjk-serif - wqy_zenhei - wqy_microhei + # Monospace fonts + (nerdfonts.override {fonts = [ + "JetBrainsMono" + ];}) # Sans/Serif fonts - cantarell-fonts - source-sans-pro - source-serif-pro noto-fonts - noto-fonts-extra noto-fonts-emoji - - # Emacs fonts - emacs-all-the-icons-fonts - material-design-icons - - # Some fonts from an old emacs config, not longer used - # etBook - # overpass + noto-fonts-cjk-sans + lxgw-wenkai ]; # TODO: Check if this works # TODO: Conflicts with kde? - # fontconfig = { - # enable = true; - # defaultFonts = { - # serif = [ "Source Han Serif Regular" ]; - # sansSerif = [ "Source Han Sans Regular" ]; - # monospace = [ "Source Han Mono Regular" ]; - # }; - # }; + fontconfig = { + enable = true; + defaultFonts = { + serif = [ "Noto Serif CJK SC" ]; + sansSerif = [ "Noto Sans CJK SC" ]; + monospace = [ "JetBrainsMono Nerd Font Mono" ]; + }; + }; }; # Define a user account. Don't forget to set a password with ‘passwd’.