blob: 6cb3791654067ee4644c4f5023961395785aa8da (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
/** A base configuration template for i3
*
* This set of configuration values is meant to work on _all_
* systems. No device specifics are included. This set must be
* merged with device specific options before being applied
*/
{ config, pkgs, ... } @ args:
let
cfg = config.libkookie.ui.i3;
xtraPkgs = pkgs // (import ./tools args);
in
rec {
# This is not configurable by design
modifier = "Mod4";
inherit (cfg) fonts;
keybindings = (import ./keys.nix { inherit cfg modifier;
pkgs = xtraPkgs; });
modes = {
# Explicitly handle the resize mode
resize = {
"h" = "resize shrink width 5 px or 5 ppt";
"j" = "resize grow height 5 px or 5 ppt";
"k" = "resize shrink height 5 px or 5 ppt";
"l" = "resize grow width 5 px or 5 ppt";
# same bindings, but for the arrow keys
"Left" = "resize shrink width 5 px or 5 ppt";
"Down" = "resize grow height 5 px or 5 ppt";
"Up" = "resize shrink height 5 px or 5 ppt";
"Right" = "resize grow width 5 px or 5 ppt";
# back to normal: Enter or Escape or $mod+r
"Return" = "mode \"default\"";
"Escape" = "mode \"default\"";
"${modifier}+r" = "mode \"default\"";
} ;
};
# The `bars` module does weird stuff so we init it ourselves
bars = [];
}
|