aboutsummaryrefslogtreecommitdiff
path: root/users/tdback/retired/rofi/default.nix
blob: 43992653d84b6c70159dfd1b1e172e5c9fb78390 (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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
{ config, pkgs, ... }:
{
  programs.rofi = {
    enable = true;
    package = pkgs.unstable.rofi;
    font = "Iosevka Comfy Motion Fixed 12";
    location = "center";
    extraConfig = {
      modi = "window,run,drun";
      icon-theme = "Papirus";
      show-icons = true;
      display-drun = "";
      display-window = "";
      drun-display-format = "{icon} {name}";
    };
    theme =
      let
        inherit (config.lib.formats.rasi) mkLiteral;
      in
      {
        "*" = {
          bg = mkLiteral "#050505";
          bg-alt = mkLiteral "#191919";
          fg = mkLiteral "#FFFFFF";
          fg-alt = mkLiteral "#787c99";
          background-color = mkLiteral "@bg";
          border = 0;
          margin = 0;
          padding = 0;
          spacing = 0;
        };

        "window" = {
          width = mkLiteral "40%";
        };

        "element" = {
          padding = 12;
          text-color = mkLiteral "@fg-alt";
        };

        "element selected" = {
          text-color = mkLiteral "@fg";
        };

        "element-text" = {
          background-color = mkLiteral "inherit";
          text-color = mkLiteral "inherit";
          vertical-align = mkLiteral "0.5";
        };

        "element-icon" = {
          size = 38;
        };

        "entry" = {
          background-color = mkLiteral "@bg-alt";
          text-color = mkLiteral "@fg";
          padding = 14;
          placeholder = "Search...";
        };

        "inputbar" = {
          children = map mkLiteral [
            "prompt"
            "entry"
          ];
        };

        "listview" = {
          columns = 2;
          lines = 6;
          background-color = mkLiteral "@bg";
        };

        "prompt" = {
          enabled = true;
          background-color = mkLiteral "@bg-alt";
          text-color = mkLiteral "@fg";
          padding = mkLiteral "14 10 0 14";
        };
      };
  };
}