Compare commits
6 commits
bd449ebd8c
...
0b72dd7dee
Author | SHA1 | Date | |
---|---|---|---|
0b72dd7dee | |||
ccf30d8414 | |||
6e3a046918 | |||
8bbf31a916 | |||
d8fd615040 | |||
7c53906edb |
29 changed files with 166 additions and 68 deletions
|
@ -61,12 +61,5 @@ in {
|
||||||
|
|
||||||
desktop = mkOption {default = "google-chrome.desktop";};
|
desktop = mkOption {default = "google-chrome.desktop";};
|
||||||
};
|
};
|
||||||
|
|
||||||
font = {
|
|
||||||
emoji = mkOption {default = "Noto Color Emoji";};
|
|
||||||
monospace = mkOption {default = "IosevkaTerm NFP SemiBold";};
|
|
||||||
sans-serif = mkOption {default = "Outfit";};
|
|
||||||
serif = mkOption {default = "Liberation Serif";};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ in {
|
||||||
bar_padding = 10;
|
bar_padding = 10;
|
||||||
bar_precedence_over_border = true; # Render borders around hyprbars
|
bar_precedence_over_border = true; # Render borders around hyprbars
|
||||||
bar_text_align = "left";
|
bar_text_align = "left";
|
||||||
bar_text_font = config.custom.font.monospace;
|
bar_text_font = config.custom.settings.fonts.monospace;
|
||||||
bar_text_size = 11;
|
bar_text_size = 11;
|
||||||
#// bar_title_enabled = false;
|
#// bar_title_enabled = false;
|
||||||
"col.text" = "rgb(93a1a1)";
|
"col.text" = "rgb(93a1a1)";
|
||||||
|
|
|
@ -185,7 +185,7 @@ in {
|
||||||
disable_hyprland_logo = true;
|
disable_hyprland_logo = true;
|
||||||
disable_splash_rendering = true;
|
disable_splash_rendering = true;
|
||||||
focus_on_activate = true;
|
focus_on_activate = true;
|
||||||
font_family = config.custom.font.monospace;
|
font_family = config.custom.settings.fonts.monospace;
|
||||||
force_default_wallpaper = 0;
|
force_default_wallpaper = 0;
|
||||||
initial_workspace_tracking = 2; # All children
|
initial_workspace_tracking = 2; # All children
|
||||||
key_press_enables_dpms = true;
|
key_press_enables_dpms = true;
|
||||||
|
|
|
@ -44,6 +44,7 @@ in {
|
||||||
home-manager.sharedModules = [
|
home-manager.sharedModules = [
|
||||||
{
|
{
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Key-Bindings
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Key-Bindings
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsbinds
|
||||||
#?? Mod = Super/Win, Alt when nested; Mod5 = AltGr
|
#?? Mod = Super/Win, Alt when nested; Mod5 = AltGr
|
||||||
#?? wev
|
#?? wev
|
||||||
programs.niri.settings.binds = let
|
programs.niri.settings.binds = let
|
||||||
|
|
|
@ -41,7 +41,6 @@ in {
|
||||||
|
|
||||||
# https://github.com/YaLTeR/niri
|
# https://github.com/YaLTeR/niri
|
||||||
# https://github.com/sodiboo/niri-flake
|
# https://github.com/sodiboo/niri-flake
|
||||||
# https://github.com/sodiboo/niri-flake/blob/main/docs.md
|
|
||||||
programs.niri = {
|
programs.niri = {
|
||||||
enable = true;
|
enable = true;
|
||||||
#// package = pkgs.niri; # nixpkgs
|
#// package = pkgs.niri; # nixpkgs
|
||||||
|
@ -50,7 +49,7 @@ in {
|
||||||
|
|
||||||
nixpkgs.overlays = [inputs.niri-flake.overlays.niri];
|
nixpkgs.overlays = [inputs.niri-flake.overlays.niri];
|
||||||
|
|
||||||
#!! Disable bundled KDE polkit agent by default
|
# Disable bundled KDE polkit agent by default
|
||||||
# https://github.com/sodiboo/niri-flake?tab=readme-ov-file#additional-notes
|
# https://github.com/sodiboo/niri-flake?tab=readme-ov-file#additional-notes
|
||||||
systemd.user.services.niri-flake-polkit.enable = cfg.polkit;
|
systemd.user.services.niri-flake-polkit.enable = cfg.polkit;
|
||||||
|
|
||||||
|
|
|
@ -15,16 +15,19 @@ in {
|
||||||
{
|
{
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Input
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Input
|
||||||
programs.niri.settings.input = {
|
programs.niri.settings.input = {
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Input#general-settings
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputfocus-follows-mouseenable
|
||||||
focus-follows-mouse = {
|
focus-follows-mouse = {
|
||||||
enable = true;
|
enable = true;
|
||||||
max-scroll-amount = "100%";
|
max-scroll-amount = "100%";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputpower-key-handlingenable
|
||||||
power-key-handling.enable = false;
|
power-key-handling.enable = false;
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputworkspace-auto-back-and-forth
|
||||||
workspace-auto-back-and-forth = true;
|
workspace-auto-back-and-forth = true;
|
||||||
|
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Input#keyboard
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputkeyboardrepeat-delay
|
||||||
keyboard = {
|
keyboard = {
|
||||||
repeat-delay = 300;
|
repeat-delay = 300;
|
||||||
repeat-rate = 40;
|
repeat-rate = 40;
|
||||||
|
@ -32,12 +35,13 @@ in {
|
||||||
|
|
||||||
# BUG: Applies to trackball device, switch to "flat" when per-device configuration is supported
|
# BUG: Applies to trackball device, switch to "flat" when per-device configuration is supported
|
||||||
# https://github.com/YaLTeR/niri/issues/371
|
# https://github.com/YaLTeR/niri/issues/371
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Input#pointing-devices
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputmouseaccel-profile
|
||||||
mouse = {
|
mouse = {
|
||||||
accel-profile = "adaptive";
|
accel-profile = "adaptive";
|
||||||
accel-speed = -0.2;
|
accel-speed = -0.2;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputtouchpadaccel-profile
|
||||||
touchpad = {
|
touchpad = {
|
||||||
accel-profile = "adaptive";
|
accel-profile = "adaptive";
|
||||||
accel-speed = 0.3;
|
accel-speed = 0.3;
|
||||||
|
@ -47,6 +51,7 @@ in {
|
||||||
scroll-factor = 0.4;
|
scroll-factor = 0.4;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsinputtrackballaccel-profile
|
||||||
trackball = {
|
trackball = {
|
||||||
accel-profile = "adaptive";
|
accel-profile = "adaptive";
|
||||||
accel-speed = 0.5;
|
accel-speed = 0.5;
|
||||||
|
|
|
@ -17,8 +17,10 @@ in {
|
||||||
programs.niri.settings.layout = let
|
programs.niri.settings.layout = let
|
||||||
gap = config.custom.gap / 2;
|
gap = config.custom.gap / 2;
|
||||||
in {
|
in {
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutalways-center-single-column
|
||||||
always-center-single-column = true;
|
always-center-single-column = true;
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutborder
|
||||||
border = {
|
border = {
|
||||||
enable = true;
|
enable = true;
|
||||||
width = config.custom.border;
|
width = config.custom.border;
|
||||||
|
@ -26,33 +28,39 @@ in {
|
||||||
inactive.color = "#00000000";
|
inactive.color = "#00000000";
|
||||||
};
|
};
|
||||||
|
|
||||||
#/// center-focused-column = mkIf config.custom.ultrawide "always";
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutcenter-focused-column
|
||||||
|
#// center-focused-column = mkIf config.custom.ultrawide "always";
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutdefault-column-width
|
||||||
default-column-width.proportion = 1.0 / 3.0; # 33%
|
default-column-width.proportion = 1.0 / 3.0; # 33%
|
||||||
|
|
||||||
# TODO: Uncomment after next release > v1.10.1
|
# TODO: Uncomment after next release > v1.10.1
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Layout#empty-workspace-above-first
|
|
||||||
#// empty-workspace-above-first = true;
|
#// empty-workspace-above-first = true;
|
||||||
|
|
||||||
focus-ring.enable = false;
|
focus-ring.enable = false;
|
||||||
gaps = gap;
|
gaps = gap;
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutinsert-hint
|
||||||
insert-hint = {
|
insert-hint = {
|
||||||
enable = true;
|
enable = true;
|
||||||
display.color = "#d3368280";
|
display.color = "#d3368280";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutpreset-column-widths
|
||||||
preset-column-widths = [
|
preset-column-widths = [
|
||||||
{proportion = 1.0 / 3.0;} # 33%, default
|
{proportion = 1.0 / 3.0;} # 33%, default
|
||||||
{proportion = 2.0 / 3.0;} # 66%
|
{proportion = 2.0 / 3.0;} # 66%
|
||||||
{proportion = 3.0 / 3.0;} # 100%
|
{proportion = 3.0 / 3.0;} # 100%
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutpreset-window-heights
|
||||||
preset-window-heights = [
|
preset-window-heights = [
|
||||||
{proportion = 2.0 / 3.0;} # 66%
|
{proportion = 2.0 / 3.0;} # 66%
|
||||||
{proportion = 1.0 / 3.0;} # 33%
|
{proportion = 1.0 / 3.0;} # 33%
|
||||||
{proportion = 3.0 / 3.0;} # 100%, default
|
{proportion = 3.0 / 3.0;} # 100%, default
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingslayoutstruts
|
||||||
struts = {
|
struts = {
|
||||||
left = gap;
|
left = gap;
|
||||||
right = gap;
|
right = gap;
|
||||||
|
|
|
@ -22,8 +22,9 @@ in {
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home-manager.sharedModules = [
|
home-manager.sharedModules = [
|
||||||
{
|
{
|
||||||
programs.niri.settings = {
|
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Miscellaneous
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Miscellaneous
|
||||||
|
programs.niri.settings = {
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingscursorhide-after-inactive-ms
|
||||||
cursor = with hm.gtk.cursorTheme; {
|
cursor = with hm.gtk.cursorTheme; {
|
||||||
# Inherit home-manager GTK settings
|
# Inherit home-manager GTK settings
|
||||||
inherit size;
|
inherit size;
|
||||||
|
@ -35,13 +36,18 @@ in {
|
||||||
|
|
||||||
# HACK: Inherit home-manager environment variables in lieu of upstream fix
|
# HACK: Inherit home-manager environment variables in lieu of upstream fix
|
||||||
# https://github.com/nix-community/home-manager/issues/2659
|
# https://github.com/nix-community/home-manager/issues/2659
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsenvironment
|
||||||
environment = mapAttrs (name: value: toString value) hm.home.sessionVariables;
|
environment = mapAttrs (name: value: toString value) hm.home.sessionVariables;
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingshotkey-overlayskip-at-startup
|
||||||
hotkey-overlay.skip-at-startup = true;
|
hotkey-overlay.skip-at-startup = true;
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsprefer-no-csd
|
||||||
prefer-no-csd = true;
|
prefer-no-csd = true;
|
||||||
|
|
||||||
#!! Not executed in a shell
|
#!! Not executed in a shell
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Key-Bindings#spawn
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Key-Bindings#spawn
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsspawn-at-startup
|
||||||
spawn-at-startup = let
|
spawn-at-startup = let
|
||||||
home = hm.home.homeDirectory;
|
home = hm.home.homeDirectory;
|
||||||
in
|
in
|
||||||
|
@ -55,6 +61,7 @@ in {
|
||||||
{command = [wallpaper];}
|
{command = [wallpaper];}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsswitch-eventslid-close
|
||||||
switch-events = {
|
switch-events = {
|
||||||
# Turn display off while inhibiting suspend
|
# Turn display off while inhibiting suspend
|
||||||
lid-close.action.spawn = [niri "msg" "action" "power-off-monitors"];
|
lid-close.action.spawn = [niri "msg" "action" "power-off-monitors"];
|
||||||
|
|
|
@ -15,6 +15,7 @@ in {
|
||||||
home-manager.sharedModules = [
|
home-manager.sharedModules = [
|
||||||
{
|
{
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Outputs
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Outputs
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsoutputs
|
||||||
#?? niri msg outputs
|
#?? niri msg outputs
|
||||||
programs.niri.settings.outputs = listToAttrs (forEach cfg.connectors (connector: {
|
programs.niri.settings.outputs = listToAttrs (forEach cfg.connectors (connector: {
|
||||||
name = connector;
|
name = connector;
|
||||||
|
|
|
@ -16,6 +16,7 @@ in {
|
||||||
# https://github.com/YaLTeR/niri/wiki/Configuration:-Window-Rules
|
# https://github.com/YaLTeR/niri/wiki/Configuration:-Window-Rules
|
||||||
programs.niri.settings = {
|
programs.niri.settings = {
|
||||||
# HACK: Name workspaces after index to use open-on-workspace rule
|
# HACK: Name workspaces after index to use open-on-workspace rule
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsworkspaces
|
||||||
#?? niri msg workspaces
|
#?? niri msg workspaces
|
||||||
# workspaces = {
|
# workspaces = {
|
||||||
# "1" = {};
|
# "1" = {};
|
||||||
|
@ -23,10 +24,10 @@ in {
|
||||||
# "3" = {};
|
# "3" = {};
|
||||||
# };
|
# };
|
||||||
|
|
||||||
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingswindow-rules
|
||||||
#?? niri msg windows
|
#?? niri msg windows
|
||||||
window-rules = [
|
window-rules = [
|
||||||
### Defaults
|
### Defaults
|
||||||
|
|
||||||
{
|
{
|
||||||
# Global
|
# Global
|
||||||
geometry-corner-radius = let
|
geometry-corner-radius = let
|
||||||
|
|
|
@ -47,7 +47,7 @@ in {
|
||||||
*:focus { outline: none; }
|
*:focus { outline: none; }
|
||||||
|
|
||||||
#window {
|
#window {
|
||||||
font: 16px ${config.custom.font.monospace};
|
font: 16px ${config.custom.settings.fonts.monospace};
|
||||||
background: none;
|
background: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -72,15 +72,15 @@ in {
|
||||||
"gnomeTheme.bookmarksToolbarUnderTabs" = true;
|
"gnomeTheme.bookmarksToolbarUnderTabs" = true;
|
||||||
#// "gnomeTheme.systemIcons" = true;
|
#// "gnomeTheme.systemIcons" = true;
|
||||||
|
|
||||||
"font.default.x-unicode" = config.custom.font.sans-serif;
|
"font.default.x-unicode" = config.custom.settings.fonts.sans-serif;
|
||||||
"font.default.x-western" = config.custom.font.sans-serif;
|
"font.default.x-western" = config.custom.settings.fonts.sans-serif;
|
||||||
"font.name-list.emoji" = config.custom.font.emoji; # System emoji
|
"font.name-list.emoji" = config.custom.settings.fonts.emoji; # System emoji
|
||||||
"font.name.monospace.x-unicode" = config.custom.font.monospace;
|
"font.name.monospace.x-unicode" = config.custom.settings.fonts.monospace;
|
||||||
"font.name.monospace.x-western" = config.custom.font.monospace;
|
"font.name.monospace.x-western" = config.custom.settings.fonts.monospace;
|
||||||
"font.name.sans-serif.x-unicode" = config.custom.font.sans-serif;
|
"font.name.sans-serif.x-unicode" = config.custom.settings.fonts.sans-serif;
|
||||||
"font.name.sans-serif.x-western" = config.custom.font.sans-serif;
|
"font.name.sans-serif.x-western" = config.custom.settings.fonts.sans-serif;
|
||||||
"font.name.serif.x-unicode" = config.custom.font.sans-serif;
|
"font.name.serif.x-unicode" = config.custom.settings.fonts.sans-serif;
|
||||||
"font.name.serif.x-western" = config.custom.font.sans-serif;
|
"font.name.serif.x-western" = config.custom.settings.fonts.sans-serif;
|
||||||
"full-screen-api.ignore-widgets" = false; # Fake fullscreen
|
"full-screen-api.ignore-widgets" = false; # Fake fullscreen
|
||||||
"full-screen-api.warning.delay" = -1;
|
"full-screen-api.warning.delay" = -1;
|
||||||
"full-screen-api.warning.timeout" = 0;
|
"full-screen-api.warning.timeout" = 0;
|
||||||
|
|
|
@ -15,7 +15,7 @@ in {
|
||||||
|
|
||||||
# https://codeberg.org/dnkl/foot/src/branch/master/foot.ini
|
# https://codeberg.org/dnkl/foot/src/branch/master/foot.ini
|
||||||
settings = {
|
settings = {
|
||||||
main.font = "${config.custom.font.monospace}:size=12";
|
main.font = "${config.custom.settings.fonts.monospace}:size=12";
|
||||||
scrollback.lines = 10000; # Default 1000
|
scrollback.lines = 10000; # Default 1000
|
||||||
|
|
||||||
# Solarized Dark
|
# Solarized Dark
|
||||||
|
|
|
@ -56,7 +56,7 @@ in {
|
||||||
# Time
|
# Time
|
||||||
{
|
{
|
||||||
color = "rgb(93a1a1)";
|
color = "rgb(93a1a1)";
|
||||||
font_family = config.custom.font.sans-serif;
|
font_family = config.custom.settings.fonts.sans-serif;
|
||||||
font_size = 64;
|
font_size = 64;
|
||||||
halign = "center";
|
halign = "center";
|
||||||
position = "0, 200";
|
position = "0, 200";
|
||||||
|
@ -73,7 +73,7 @@ in {
|
||||||
# Date
|
# Date
|
||||||
{
|
{
|
||||||
color = "rgb(93a1a1)";
|
color = "rgb(93a1a1)";
|
||||||
font_family = config.custom.font.sans-serif;
|
font_family = config.custom.settings.fonts.sans-serif;
|
||||||
font_size = 32;
|
font_size = 32;
|
||||||
halign = "center";
|
halign = "center";
|
||||||
position = "0, 100";
|
position = "0, 100";
|
||||||
|
@ -85,7 +85,7 @@ in {
|
||||||
# Fingerprint
|
# Fingerprint
|
||||||
{
|
{
|
||||||
color = "rgb(93a1a1)";
|
color = "rgb(93a1a1)";
|
||||||
font_family = config.custom.font.monospace;
|
font_family = config.custom.settings.fonts.monospace;
|
||||||
font_size = 42;
|
font_size = 42;
|
||||||
halign = "center";
|
halign = "center";
|
||||||
position = "0, -100";
|
position = "0, -100";
|
||||||
|
|
|
@ -16,7 +16,7 @@ in {
|
||||||
shellIntegration.mode = "no-cursor"; # Disable forced beam cursor
|
shellIntegration.mode = "no-cursor"; # Disable forced beam cursor
|
||||||
|
|
||||||
font = {
|
font = {
|
||||||
name = config.custom.font.monospace;
|
name = config.custom.settings.fonts.monospace;
|
||||||
size = 14;
|
size = 14;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -103,7 +103,7 @@ in {
|
||||||
fullScreen = true;
|
fullScreen = true;
|
||||||
quickSplash = true;
|
quickSplash = true;
|
||||||
size = "${toString (config.custom.width / 2)}x${toString (config.custom.height / 2)}";
|
size = "${toString (config.custom.width / 2)}x${toString (config.custom.height / 2)}";
|
||||||
uiFont = config.custom.font.monospace;
|
uiFont = config.custom.settings.fonts.monospace;
|
||||||
uiSize = 24;
|
uiSize = 24;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -32,7 +32,7 @@ in {
|
||||||
|
|
||||||
#?? rofi-theme-selector
|
#?? rofi-theme-selector
|
||||||
theme = "custom";
|
theme = "custom";
|
||||||
font = "${config.custom.font.monospace} 16";
|
font = "${config.custom.settings.fonts.monospace} 16";
|
||||||
|
|
||||||
# https://github.com/davatorium/rofi/blob/next/CONFIG.md
|
# https://github.com/davatorium/rofi/blob/next/CONFIG.md
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
|
|
|
@ -31,7 +31,7 @@ in {
|
||||||
indicator-idle-visible = true;
|
indicator-idle-visible = true;
|
||||||
indicator-radius = 150;
|
indicator-radius = 150;
|
||||||
font-size = 48 * config.custom.scale;
|
font-size = 48 * config.custom.scale;
|
||||||
font = config.custom.font.monospace;
|
font = config.custom.settings.fonts.monospace;
|
||||||
image = mkIf config.custom.wallpaper "/tmp/altered.png";
|
image = mkIf config.custom.wallpaper "/tmp/altered.png";
|
||||||
bs-hl-color = "93a1a1";
|
bs-hl-color = "93a1a1";
|
||||||
color = "073642";
|
color = "073642";
|
||||||
|
|
|
@ -138,11 +138,11 @@ in {
|
||||||
theme = {
|
theme = {
|
||||||
style = ''
|
style = ''
|
||||||
#box {
|
#box {
|
||||||
font: larger ${config.custom.font.sans-serif};
|
font: larger ${config.custom.settings.fonts.sans-serif};
|
||||||
}
|
}
|
||||||
|
|
||||||
placeholder {
|
placeholder {
|
||||||
font: larger ${config.custom.font.monospace};
|
font: larger ${config.custom.settings.fonts.monospace};
|
||||||
}
|
}
|
||||||
|
|
||||||
${readFile ./style.css}
|
${readFile ./style.css}
|
||||||
|
|
|
@ -67,7 +67,7 @@ in {
|
||||||
#?? GTK_DEBUG=interactive waybar
|
#?? GTK_DEBUG=interactive waybar
|
||||||
style = let
|
style = let
|
||||||
border = toString config.custom.border;
|
border = toString config.custom.border;
|
||||||
font = config.custom.font.monospace;
|
font = config.custom.settings.fonts.monospace;
|
||||||
gap = toString config.custom.gap;
|
gap = toString config.custom.gap;
|
||||||
in ''
|
in ''
|
||||||
* {
|
* {
|
||||||
|
@ -95,7 +95,7 @@ in {
|
||||||
#!! Some settings are commonly available for use but not documented per module
|
#!! Some settings are commonly available for use but not documented per module
|
||||||
common = {
|
common = {
|
||||||
# https://github.com/Alexays/Waybar/issues/1800
|
# https://github.com/Alexays/Waybar/issues/1800
|
||||||
smooth-scrolling-threshold = 2;
|
smooth-scrolling-threshold = 1; #!! Affects discrete scroll events
|
||||||
|
|
||||||
on-scroll-down =
|
on-scroll-down =
|
||||||
if config.custom.desktop == "niri"
|
if config.custom.desktop == "niri"
|
||||||
|
|
|
@ -21,7 +21,7 @@ in {
|
||||||
local act = wezterm.action
|
local act = wezterm.action
|
||||||
local config = wezterm.config_builder()
|
local config = wezterm.config_builder()
|
||||||
|
|
||||||
config.font = wezterm.font('${config.custom.font.monospace}')
|
config.font = wezterm.font('${config.custom.settings.fonts.monospace}')
|
||||||
|
|
||||||
-- # TODO: Remove when using Wayland
|
-- # TODO: Remove when using Wayland
|
||||||
config.font_size = ${toString (14 * config.custom.scale)}
|
config.font_size = ${toString (14 * config.custom.scale)}
|
||||||
|
|
22
options/custom/programs/xwayland.nix
Normal file
22
options/custom/programs/xwayland.nix
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
cfg = config.custom.programs.xwayland;
|
||||||
|
in {
|
||||||
|
options.custom.programs.xwayland = {
|
||||||
|
enable = mkOption {default = false;};
|
||||||
|
xwayland-run = mkOption {default = true;};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
# https://wiki.archlinux.org/title/Wayland#Xwayland
|
||||||
|
programs.xwayland.enable = true;
|
||||||
|
|
||||||
|
# https://gitlab.freedesktop.org/ofourdan/xwayland-run
|
||||||
|
environment.systemPackages = mkIf cfg.xwayland-run [pkgs.xwayland-run];
|
||||||
|
};
|
||||||
|
}
|
|
@ -21,7 +21,7 @@ in {
|
||||||
anchor = "top-center";
|
anchor = "top-center";
|
||||||
backgroundColor = "#073642";
|
backgroundColor = "#073642";
|
||||||
borderColor = "#002b36";
|
borderColor = "#002b36";
|
||||||
font = "${config.custom.font.sans-serif} 12";
|
font = "${config.custom.settings.fonts.sans-serif} 12";
|
||||||
layer = "overlay";
|
layer = "overlay";
|
||||||
margin = "20";
|
margin = "20";
|
||||||
padding = "10";
|
padding = "10";
|
||||||
|
|
|
@ -25,7 +25,7 @@ in {
|
||||||
fill-tabs = mkBoolean true;
|
fill-tabs = mkBoolean true;
|
||||||
floating-controls = mkBoolean true;
|
floating-controls = mkBoolean true;
|
||||||
floating-controls-hover-area = mkUint32 10;
|
floating-controls-hover-area = mkUint32 10;
|
||||||
font = mkString "${config.custom.font.monospace} 14";
|
font = mkString "${config.custom.settings.fonts.monospace} 14";
|
||||||
headerbar-drag-area = mkBoolean false;
|
headerbar-drag-area = mkBoolean false;
|
||||||
notify-process-completion = mkBoolean false;
|
notify-process-completion = mkBoolean false;
|
||||||
opacity = mkUint32 100;
|
opacity = mkUint32 100;
|
||||||
|
@ -71,7 +71,7 @@ in {
|
||||||
cursor-blink = mkBoolean false;
|
cursor-blink = mkBoolean false;
|
||||||
gtk-enable-primary-paste = mkBoolean false;
|
gtk-enable-primary-paste = mkBoolean false;
|
||||||
color-scheme = mkString "prefer-dark";
|
color-scheme = mkString "prefer-dark";
|
||||||
monospace-font-name = mkString "${config.custom.font.monospace} 14";
|
monospace-font-name = mkString "${config.custom.settings.fonts.monospace} 14";
|
||||||
};
|
};
|
||||||
|
|
||||||
# GNOME Files
|
# GNOME Files
|
||||||
|
|
|
@ -6,9 +6,9 @@
|
||||||
with lib; let
|
with lib; let
|
||||||
cfg = config.custom.settings.dconf;
|
cfg = config.custom.settings.dconf;
|
||||||
in {
|
in {
|
||||||
options.custom.settings.dconf.default = mkOption {default = false;};
|
options.custom.settings.dconf.enable = mkOption {default = false;};
|
||||||
|
|
||||||
config.custom.settings.dconf = mkIf cfg.default {
|
config.custom.settings.dconf = mkIf cfg.enable {
|
||||||
apps.enable = true;
|
apps.enable = true;
|
||||||
gnome.enable = true;
|
gnome.enable = true;
|
||||||
gnome-shell.enable = true;
|
gnome-shell.enable = true;
|
||||||
|
|
|
@ -16,9 +16,10 @@ with lib; {
|
||||||
})
|
})
|
||||||
|
|
||||||
(mkIf config.custom.minimal {
|
(mkIf config.custom.minimal {
|
||||||
dconf.default = true;
|
dconf.enable = true;
|
||||||
fonts.enable = true;
|
fonts.enable = true;
|
||||||
gtk.enable = true;
|
gtk.enable = true;
|
||||||
|
icons.enable = true;
|
||||||
qt.enable = true;
|
qt.enable = true;
|
||||||
#// stylix.enable = true;
|
#// stylix.enable = true;
|
||||||
xdg.enable = true;
|
xdg.enable = true;
|
||||||
|
|
|
@ -7,7 +7,13 @@
|
||||||
with lib; let
|
with lib; let
|
||||||
cfg = config.custom.settings.fonts;
|
cfg = config.custom.settings.fonts;
|
||||||
in {
|
in {
|
||||||
options.custom.settings.fonts.enable = mkOption {default = false;};
|
options.custom.settings.fonts = {
|
||||||
|
enable = mkOption {default = false;};
|
||||||
|
emoji = mkOption {default = "Noto Color Emoji";};
|
||||||
|
monospace = mkOption {default = "IosevkaTerm NFP SemiBold";};
|
||||||
|
sans-serif = mkOption {default = "Outfit";};
|
||||||
|
serif = mkOption {default = "Liberation Serif";};
|
||||||
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
# https://wiki.nixos.org/wiki/Fonts
|
# https://wiki.nixos.org/wiki/Fonts
|
||||||
|
@ -52,10 +58,10 @@ in {
|
||||||
|
|
||||||
#?? fc-list --brief | grep family: | sort
|
#?? fc-list --brief | grep family: | sort
|
||||||
fontconfig.defaultFonts = {
|
fontconfig.defaultFonts = {
|
||||||
emoji = [config.custom.font.emoji];
|
emoji = [cfg.emoji];
|
||||||
monospace = [config.custom.font.monospace];
|
monospace = [cfg.monospace];
|
||||||
sansSerif = [config.custom.font.sans-serif];
|
sansSerif = [cfg.sans-serif];
|
||||||
serif = [config.custom.font.serif];
|
serif = [cfg.serif];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -14,28 +14,18 @@ in {
|
||||||
css = readFile ./style.css;
|
css = readFile ./style.css;
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
gtk3.extraCss = css;
|
|
||||||
|
|
||||||
gtk4 = {
|
font = with config.custom.settings.fonts; {
|
||||||
extraConfig.gtk-hint-font-metrics = 1; # Fix blurry fonts
|
name = sans-serif;
|
||||||
extraCss = css;
|
|
||||||
};
|
|
||||||
|
|
||||||
font = {
|
|
||||||
name = config.custom.font.sans-serif;
|
|
||||||
size = 12;
|
size = 12;
|
||||||
};
|
};
|
||||||
|
|
||||||
iconTheme = {
|
cursorTheme = with config.custom.settings.icons.cursor; {
|
||||||
name = "Papirus-Dark";
|
inherit name package size;
|
||||||
package = pkgs.papirus-icon-theme;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# BUG: home.pointerCursor breaks XCURSOR_PATH for some child windows, so avoid that workaround
|
iconTheme = with config.custom.settings.icons.icon; {
|
||||||
cursorTheme = {
|
inherit name package;
|
||||||
size = 24;
|
|
||||||
name = "GoogleDot-Black";
|
|
||||||
package = pkgs.google-cursor;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
theme = {
|
theme = {
|
||||||
|
@ -45,6 +35,15 @@ in {
|
||||||
# https://github.com/nix-community/home-manager/issues/5133
|
# https://github.com/nix-community/home-manager/issues/5133
|
||||||
#// package = pkgs.adw-gtk3;
|
#// package = pkgs.adw-gtk3;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
gtk3 = {
|
||||||
|
extraCss = css;
|
||||||
|
};
|
||||||
|
|
||||||
|
gtk4 = {
|
||||||
|
extraConfig.gtk-hint-font-metrics = 1; # Fix blurry fonts
|
||||||
|
extraCss = css;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
55
options/custom/settings/icons.nix
Normal file
55
options/custom/settings/icons.nix
Normal file
|
@ -0,0 +1,55 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
cfg = config.custom.settings.icons;
|
||||||
|
in {
|
||||||
|
options.custom.settings.icons = {
|
||||||
|
enable = mkOption {default = false;};
|
||||||
|
|
||||||
|
cursor = {
|
||||||
|
# https://github.com/ful1e5/Google_Cursor
|
||||||
|
name = mkOption {default = "GoogleDot-Black";};
|
||||||
|
package = mkOption {default = pkgs.google-cursor;};
|
||||||
|
size = mkOption {default = 24;};
|
||||||
|
};
|
||||||
|
|
||||||
|
icon = {
|
||||||
|
# https://github.com/PapirusDevelopmentTeam/papirus-icon-theme
|
||||||
|
name = mkOption {default = "Papirus-Dark";};
|
||||||
|
package = mkOption {default = pkgs.papirus-icon-theme;};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
environment.systemPackages = [cfg.cursor.package cfg.icon.package];
|
||||||
|
|
||||||
|
# BUG: home.pointerCursor breaks XCURSOR_PATH for some child windows, so avoid that workaround
|
||||||
|
# HACK: Copy home-manager index.theme without setting XCURSOR_* environment variables
|
||||||
|
home-manager.sharedModules = let
|
||||||
|
# https://github.com/nix-community/home-manager/blob/59a4c43e9ba6db24698c112720a58a334117de83/modules/config/home-cursor.nix#L66C3-L77C8
|
||||||
|
defaultIndexThemePackage = pkgs.writeTextFile {
|
||||||
|
name = "index.theme";
|
||||||
|
destination = "/share/icons/default/index.theme";
|
||||||
|
|
||||||
|
text = ''
|
||||||
|
[Icon Theme]
|
||||||
|
Name=Default
|
||||||
|
Comment=Default Cursor Theme
|
||||||
|
Inherits=${cfg.cursor.name}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in [
|
||||||
|
{
|
||||||
|
# https://github.com/nix-community/home-manager/blob/59a4c43e9ba6db24698c112720a58a334117de83/modules/config/home-cursor.nix#L161
|
||||||
|
home.file.".icons/default/index.theme".source = "${defaultIndexThemePackage}/share/icons/default/index.theme";
|
||||||
|
home.file.".icons/${cfg.cursor.name}".source = "${cfg.cursor.package}/share/icons/${cfg.cursor.name}";
|
||||||
|
xdg.dataFile."icons/default/index.theme".source = "${defaultIndexThemePackage}/share/icons/default/index.theme";
|
||||||
|
xdg.dataFile."icons/${cfg.cursor.name}".source = "${cfg.cursor.package}/share/icons/${cfg.cursor.name}";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue