summaryrefslogtreecommitdiff
path: root/common/programs/rofi.nix
diff options
context:
space:
mode:
Diffstat (limited to 'common/programs/rofi.nix')
-rw-r--r--common/programs/rofi.nix346
1 files changed, 80 insertions, 266 deletions
diff --git a/common/programs/rofi.nix b/common/programs/rofi.nix
index 66ff00c..518bd77 100644
--- a/common/programs/rofi.nix
+++ b/common/programs/rofi.nix
@@ -7,9 +7,14 @@
{
programs.rofi = {
enable = true;
- font = "Lilex Nerd Font";
+ font = "JetBrainsMono Nerd Font";
plugins = with pkgs; [ rofi-emoji ];
theme = "~/.config/rofi/themes/config.rasi";
+ extraConfig = {
+ show-icons = true;
+ icon-theme = "Papirus";
+ drun-display-format = "{name}";
+ };
};
home.packages = [
@@ -17,315 +22,124 @@
];
xdg.configFile = {
- "rofi/shared/default-colors.rasi" = {
+ "rofi/shared/colors.rasi" = {
enable = !config.beeMods.matugen.enable;
text =
# rasi
''
* {
- background: #000000FF;
- background-alt: #101010FF;
- foreground: #FFFFFFFF;
- selected: #62AEEFFF;
- active: #98C379FF;
- urgent: #E06B74FF;
+ bg: #212121;
+ bg-alt: #2d2d2d;
+ fg: #ffffffdd;
+ fg-dim: #616161;
+ accent: #80cbc4;
+ selected-bg: #424242;
+ selected-fg: #80cbc4;
+ urgent: #ef9a9a;
+ outline: #424242;
}
'';
};
- };
- # Dont scroll its just rofi theme
- xdg.configFile = {
"rofi/themes/config.rasi" = {
enable = true;
text =
# rasi
''
- /**
- *
- * Author : Aditya Shakya (adi1090x)
- * Github : @adi1090x
- *
- * Rofi Theme File
- * Rofi Version: 1.7.3
- **/
-
- /*****----- Configuration -----*****/
- configuration {
- modi: "drun";
- show-icons: true;
- display-drun: "drun";
- display-run: "";
- display-filebrowser: "";
- display-window: "";
- font: "monospace 12";
- drun-display-format: "{name} [<span weight='light' size='small'><i>({generic})</i></span>]";
- window-format: "{w} · {c} · {t}";
- }
-
- /*****----- Global Properties -----*****/
- ${
- if config.beeMods.matugen.enable then
- ''@import "shared/colors.rasi"''
- else
- ''@import "shared/default-colors.rasi"''
- }
-
+ @import "shared/colors.rasi"
* {
- border-colour: var(selected);
- handle-colour: var(selected);
- background-colour: var(background);
- foreground-colour: var(foreground);
- alternate-background: var(background-alt);
- normal-background: var(background);
- normal-foreground: var(foreground);
- urgent-background: var(urgent);
- urgent-foreground: var(background);
- active-background: var(active);
- active-foreground: var(background);
- selected-normal-background: var(selected);
- selected-normal-foreground: var(background);
- selected-urgent-background: var(active);
- selected-urgent-foreground: var(background);
- selected-active-background: var(urgent);
- selected-active-foreground: var(background);
- alternate-normal-background: var(background);
- alternate-normal-foreground: var(foreground);
- alternate-urgent-background: var(urgent);
- alternate-urgent-foreground: var(background);
- alternate-active-background: var(active);
- alternate-active-foreground: var(background);
+ background-color: transparent;
+ text-color: @fg;
+ border: 0px;
+ margin: 0px;
+ padding: 0px;
+ spacing: 0px;
}
- /*****----- Main Window -----*****/
window {
- /* properties for window widget */
- transparency: "real";
- location: center;
- anchor: center;
- fullscreen: false;
- width: 600px;
- x-offset: 0px;
- y-offset: 0px;
-
- /* properties for all widgets */
- enabled: true;
- margin: 0px;
- padding: 0px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- cursor: "default";
- background-color: @background-colour;
+ background-color: @bg;
+ border-radius: 0px;
+ border: 2px;
+ border-color: @outline;
+ width: 680px;
+ padding: 10px;
}
- /*****----- Main Box -----*****/
mainbox {
- enabled: true;
- spacing: 0px;
- margin: 0px;
- padding: 0px;
- border: 0px solid;
- border-radius: 0px 0px 0px 0px;
- border-color: @border-colour;
- background-color: transparent;
- children: [ "inputbar", "listview" ];
+ background-color: transparent;
+ spacing: 8px;
}
- /*****----- Inputbar -----*****/
inputbar {
- enabled: true;
- spacing: 0px;
- margin: 0px;
- padding: 0px;
- border: 0px 0px 1px 0px;
- border-radius: 0px;
- border-color: @alternate-background;
- background-color: @background-colour;
- text-color: @foreground-colour;
- children: [ "prompt", "entry" ];
+ background-color: @bg-alt;
+ border-radius: 0px;
+ padding: 10px 12px;
+ spacing: 8px;
+ children: [entry];
}
- prompt {
- enabled: true;
- padding: 15px;
- border: 0px 1px 0px 0px;
- border-radius: 0px;
- border-color: @alternate-background;
- background-color: inherit;
- text-color: inherit;
- }
- textbox-prompt-colon {
- enabled: true;
- expand: false;
- str: "::";
- background-color: inherit;
- text-color: inherit;
- }
entry {
- enabled: true;
- padding: 15px;
- background-color: inherit;
- text-color: inherit;
- cursor: text;
- placeholder: "";
- placeholder-color: inherit;
+ background-color: transparent;
+ text-color: @fg;
+ placeholder-color: @fg-dim;
+ placeholder: "Search...";
+ cursor: text;
+ font: "JetBrainsMono Nerd Font Bold 13";
}
- /*****----- Listview -----*****/
listview {
- enabled: true;
- columns: 1;
- lines: 8;
- cycle: true;
- dynamic: true;
- scrollbar: false;
- layout: vertical;
- reverse: false;
- fixed-height: true;
- fixed-columns: true;
-
- spacing: 0px;
- margin: 0px;
- padding: 0px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- background-color: transparent;
- text-color: @foreground-colour;
- cursor: "default";
- }
- scrollbar {
- handle-width: 5px ;
- handle-color: @handle-colour;
- border-radius: 0px;
- background-color: @alternate-background;
+ background-color: transparent;
+ columns: 1;
+ lines: 5;
+ spacing: 2px;
+ scrollbar: false;
}
- /*****----- Elements -----*****/
element {
- enabled: true;
- spacing: 10px;
- margin: 0px;
- padding: 8px 15px;
- border: 0px 0px 1px 0px;
- border-radius: 0px;
- border-color: @alternate-background;
- background-color: transparent;
- text-color: @foreground-colour;
- cursor: pointer;
- }
- element normal.normal {
- background-color: var(normal-background);
- text-color: var(normal-foreground);
- }
- element normal.urgent {
- background-color: var(urgent-background);
- text-color: var(urgent-foreground);
- }
- element normal.active {
- background-color: var(active-background);
- text-color: var(active-foreground);
- }
- element selected.normal {
- background-color: var(alternate-background);
- text-color: var(foreground-colour);
+ background-color: transparent;
+ border-radius: 0px;
+ padding: 8px 12px;
+ spacing: 12px;
+ children: [element-icon, element-text];
}
- element selected.urgent {
- background-color: var(selected-urgent-background);
- text-color: var(selected-urgent-foreground);
- }
- element selected.active {
- background-color: var(selected-active-background);
- text-color: var(selected-active-foreground);
- }
- element alternate.normal {
- background-color: var(alternate-normal-background);
- text-color: var(alternate-normal-foreground);
- }
- element alternate.urgent {
- background-color: var(alternate-urgent-background);
- text-color: var(alternate-urgent-foreground);
- }
- element alternate.active {
- background-color: var(alternate-active-background);
- text-color: var(alternate-active-foreground);
- }
- element-icon {
- background-color: transparent;
- text-color: inherit;
- size: 32px;
- cursor: inherit;
- }
- element-text {
- background-color: transparent;
- text-color: inherit;
- highlight: inherit;
- cursor: inherit;
- vertical-align: 0.5;
- horizontal-align: 0.0;
+
+ element normal normal {
+ background-color: transparent;
+ text-color: @fg;
}
- /*****----- Mode Switcher -----*****/
- mode-switcher{
- enabled: true;
- spacing: 10px;
- margin: 0px;
- padding: 0px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- background-color: transparent;
- text-color: @foreground-colour;
+ element alternate normal {
+ background-color: transparent;
+ text-color: @fg;
}
- button {
- padding: 10px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- background-color: @alternate-background;
- text-color: inherit;
- cursor: pointer;
+
+ element selected normal {
+ background-color: @selected-bg;
+ text-color: @selected-fg;
}
- button selected {
- background-color: var(selected-normal-background);
- text-color: var(selected-normal-foreground);
+
+ element normal urgent {
+ text-color: @urgent;
}
- /*****----- Message -----*****/
- message {
- enabled: true;
- margin: 0px;
- padding: 0px;
- border: 0px solid;
- border-radius: 0px 0px 0px 0px;
- border-color: @border-colour;
- background-color: transparent;
- text-color: @foreground-colour;
+ element selected urgent {
+ background-color: @selected-bg;
+ text-color: @urgent;
}
- textbox {
- padding: 10px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- background-color: @alternate-background;
- text-color: @foreground-colour;
- vertical-align: 0.5;
- horizontal-align: 0.0;
- highlight: none;
- placeholder-color: @foreground-colour;
- blink: true;
- markup: true;
+
+ element-icon {
+ background-color: transparent;
+ size: 22px;
}
- error-message {
- padding: 0px;
- border: 0px solid;
- border-radius: 0px;
- border-color: @border-colour;
- background-color: @background-colour;
- text-color: @foreground-colour;
+
+ element-text {
+ background-color: transparent;
+ text-color: inherit;
+ vertical-align: 0.5;
+ font: "JetBrainsMono Nerd Font Bold 13";
}
'';
};
+
};
}