some more updates
This commit is contained in:
parent
270e52070d
commit
d5ce93f871
2 changed files with 77 additions and 66 deletions
|
|
@ -44,6 +44,7 @@
|
||||||
wallpaper = ../../misc/portrait.png;
|
wallpaper = ../../misc/portrait.png;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
bindWorkspaces = "interlaced";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,8 @@
|
||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (lib) mkOption mkIf types trivial strings replaceStrings;
|
inherit (lib) mkOption mkIf types trivial strings;
|
||||||
inherit (builtins) concatStringsSep elem;
|
inherit (builtins) concatStringsSep elem genList elemAt;
|
||||||
cfg = config.horseman.wm.hyprland;
|
cfg = config.horseman.wm.hyprland;
|
||||||
homeCfg = config.horseman;
|
homeCfg = config.horseman;
|
||||||
keybinding = types.submodule {
|
keybinding = types.submodule {
|
||||||
|
|
@ -158,6 +158,10 @@ in {
|
||||||
|
|
||||||
monitors = {
|
monitors = {
|
||||||
defaultMonitor = mkOption {type = types.bool;};
|
defaultMonitor = mkOption {type = types.bool;};
|
||||||
|
bindWorkspaces = mkOption {
|
||||||
|
type = types.enum ["no" "interlaced"];
|
||||||
|
default = "no";
|
||||||
|
};
|
||||||
|
|
||||||
displays = mkOption {
|
displays = mkOption {
|
||||||
type = types.listOf (types.submodule {
|
type = types.listOf (types.submodule {
|
||||||
|
|
@ -225,8 +229,6 @@ in {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -269,7 +271,7 @@ in {
|
||||||
${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${
|
${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${
|
||||||
if (elem "m" kb.flags) # Mouse binds take one argument less
|
if (elem "m" kb.flags) # Mouse binds take one argument less
|
||||||
then ""
|
then ""
|
||||||
else ", ${replaceStrings ["%"] ["%%"] kb.params}"
|
else ", ${kb.params}"
|
||||||
}")
|
}")
|
||||||
cfg.config.keybindings.binds)}
|
cfg.config.keybindings.binds)}
|
||||||
|
|
||||||
|
|
@ -280,7 +282,7 @@ in {
|
||||||
${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${
|
${concatStringsSep "\n" (map (kb: "bind${concatStringsSep "" kb.flags} = ${concatStringsSep " " kb.mods}, ${kb.key}, ${kb.dispatcher}${
|
||||||
if (elem "m" kb.flags) # Mouse binds take one argument less
|
if (elem "m" kb.flags) # Mouse binds take one argument less
|
||||||
then ""
|
then ""
|
||||||
else ", ${replaceStrings ["%"] ["%%"] kb.params}"
|
else ", ${kb.params}"
|
||||||
}")
|
}")
|
||||||
sm.binds)}
|
sm.binds)}
|
||||||
|
|
||||||
|
|
@ -330,7 +332,7 @@ in {
|
||||||
|
|
||||||
${concatStringsSep "\n " (map (bez: "bezier = ${bez.name}, ${strings.floatToString bez.startX}, ${strings.floatToString bez.startY}, ${strings.floatToString bez.endX}, ${strings.floatToString bez.endY}") cfg.config.animations.beziers)}
|
${concatStringsSep "\n " (map (bez: "bezier = ${bez.name}, ${strings.floatToString bez.startX}, ${strings.floatToString bez.startY}, ${strings.floatToString bez.endX}, ${strings.floatToString bez.endY}") cfg.config.animations.beziers)}
|
||||||
|
|
||||||
${concatStringsSep "\n " (map (anim: "animation = ${anim.name}, ${toString anim.on}, ${strings.floatToString anim.speed}, ${anim.curve}, ${replaceStrings ["%"] ["%%"] anim.style}") cfg.config.animations.animations)}
|
${concatStringsSep "\n " (map (anim: "animation = ${anim.name}, ${toString anim.on}, ${strings.floatToString anim.speed}, ${anim.curve}, ${anim.style}") cfg.config.animations.animations)}
|
||||||
}
|
}
|
||||||
|
|
||||||
dwindle {
|
dwindle {
|
||||||
|
|
@ -372,68 +374,76 @@ in {
|
||||||
else ""
|
else ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
${concatStringsSep "\n" (map (wr: "windowrule = " + wr) cfg.config.windowrules)}
|
||||||
|
|
||||||
${concatStringsSep "\n" (map (ws: "workspace = " + ws) cfg.config.workspaces)}
|
${concatStringsSep "\n" (map (ws: "workspace = " + ws) cfg.config.workspaces)}
|
||||||
|
|
||||||
${concatStringsSep "\n" (map (wr: "windowrule = " + replaceStrings ["%"] ["%%"] wr) cfg.config.windowrules)}
|
${
|
||||||
|
concatStringsSep "\n" (
|
||||||
|
if cfg.config.monitors.bindWorkspaces == "interlaced"
|
||||||
|
then (map (x: "workspace = ${toString (x + 1)}, persistent:true, monitor:${(elemAt cfg.config.monitors.displays (x - (2 * (x / 2)))).output}") (genList (x: x) 10))
|
||||||
|
else []
|
||||||
|
)
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
|
||||||
|
xdg.configFile."hypr/hyprlock.conf".text = ''
|
||||||
|
$font = Monospace
|
||||||
|
|
||||||
|
general {
|
||||||
|
hide_cursor = false
|
||||||
|
}
|
||||||
|
|
||||||
|
animations {
|
||||||
|
enabled = true
|
||||||
|
bezier = linear, 1, 1, 0, 0
|
||||||
|
animation = fadeIn, 1, 5, linear
|
||||||
|
animation = fadeOut, 1, 5, linear
|
||||||
|
animation = inputFieldDots, 1, 2, linear
|
||||||
|
}
|
||||||
|
|
||||||
|
background {
|
||||||
|
monitor =
|
||||||
|
path = screenshot
|
||||||
|
blur_passes = 3
|
||||||
|
}
|
||||||
|
|
||||||
|
input-field {
|
||||||
|
monitor =
|
||||||
|
size = 20%, 5%
|
||||||
|
outline_thickness = 3
|
||||||
|
inner_color = rgba(0, 0, 0, 0.0) # no fill
|
||||||
|
|
||||||
|
outer_color = rgba(33ccffee) rgba(00ff99ee) 45deg
|
||||||
|
check_color = rgba(00ff99ee) rgba(ff6633ee) 120deg
|
||||||
|
fail_color = rgba(ff6633ee) rgba(ff0066ee) 40deg
|
||||||
|
|
||||||
|
font_color = rgb(143, 143, 143)
|
||||||
|
fade_on_empty = false
|
||||||
|
rounding = 15
|
||||||
|
|
||||||
|
font_family = $font
|
||||||
|
placeholder_text = Input password...
|
||||||
|
fail_text = $PAMFAIL
|
||||||
|
|
||||||
|
dots_spacing = 0.3
|
||||||
|
|
||||||
|
position = 0, -20
|
||||||
|
halign = center
|
||||||
|
valign = center
|
||||||
|
}
|
||||||
|
|
||||||
|
label {
|
||||||
|
monitor =
|
||||||
|
text = $TIME
|
||||||
|
font_size = 90
|
||||||
|
font_family = $font
|
||||||
|
|
||||||
|
position = 0, -50
|
||||||
|
halign = center
|
||||||
|
valign = top
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
xdg.configFile."hypr/hyprlock.conf".text = ''
|
|
||||||
$font = Monospace
|
|
||||||
|
|
||||||
general {
|
|
||||||
hide_cursor = false
|
|
||||||
}
|
|
||||||
|
|
||||||
animations {
|
|
||||||
enabled = true
|
|
||||||
bezier = linear, 1, 1, 0, 0
|
|
||||||
animation = fadeIn, 1, 5, linear
|
|
||||||
animation = fadeOut, 1, 5, linear
|
|
||||||
animation = inputFieldDots, 1, 2, linear
|
|
||||||
}
|
|
||||||
|
|
||||||
background {
|
|
||||||
monitor =
|
|
||||||
path = screenshot
|
|
||||||
blur_passes = 3
|
|
||||||
}
|
|
||||||
|
|
||||||
input-field {
|
|
||||||
monitor =
|
|
||||||
size = 20%, 5%
|
|
||||||
outline_thickness = 3
|
|
||||||
inner_color = rgba(0, 0, 0, 0.0) # no fill
|
|
||||||
|
|
||||||
outer_color = rgba(33ccffee) rgba(00ff99ee) 45deg
|
|
||||||
check_color = rgba(00ff99ee) rgba(ff6633ee) 120deg
|
|
||||||
fail_color = rgba(ff6633ee) rgba(ff0066ee) 40deg
|
|
||||||
|
|
||||||
font_color = rgb(143, 143, 143)
|
|
||||||
fade_on_empty = false
|
|
||||||
rounding = 15
|
|
||||||
|
|
||||||
font_family = $font
|
|
||||||
placeholder_text = Input password...
|
|
||||||
fail_text = $PAMFAIL
|
|
||||||
|
|
||||||
dots_spacing = 0.3
|
|
||||||
|
|
||||||
position = 0, -20
|
|
||||||
halign = center
|
|
||||||
valign = center
|
|
||||||
}
|
|
||||||
|
|
||||||
label {
|
|
||||||
monitor =
|
|
||||||
text = $TIME
|
|
||||||
font_size = 90
|
|
||||||
font_family = $font
|
|
||||||
|
|
||||||
position = 0, -50
|
|
||||||
halign = center
|
|
||||||
valign = top
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue