aboutsummaryrefslogtreecommitdiffstats
path: root/oni
diff options
context:
space:
mode:
authorGravatar Tom Willemse2022-07-03 19:00:35 -0700
committerGravatar Tom Willemse2022-07-03 19:06:32 -0700
commit5c200f0cb4bd74fd8d3e3d59c25e6024ca816066 (patch)
tree6743d5fe334cc1306f9dc2b3b36658cf944d3847 /oni
parentdc631e498f3b87bf47c28bfef1265a6de21019bf (diff)
downloadnew-dotfiles-5c200f0cb4bd74fd8d3e3d59c25e6024ca816066.tar.gz
new-dotfiles-5c200f0cb4bd74fd8d3e3d59c25e6024ca816066.zip
Fixup rofi theme configuration
This is a temporary fix. I've switched from using ‘@theme’ to ‘@import’ because the former discards the default theme, and apparently my theme makes some assumptions about the state of things and requires the default theme to work. The proper fix would be to fix my theme instead. This change also fixes a bunch of typos and fixes the use of references within the theme. References aren't strictly necessary, but my current theme relies on them and they are technically a valid part of the configuration.
Diffstat (limited to 'oni')
-rw-r--r--oni/home/data/config.scm37
-rw-r--r--oni/home/services/rofi.scm8
2 files changed, 21 insertions, 24 deletions
diff --git a/oni/home/data/config.scm b/oni/home/data/config.scm
index dfba9ab..0cefc66 100644
--- a/oni/home/data/config.scm
+++ b/oni/home/data/config.scm
@@ -99,41 +99,41 @@
(orange . "#faa41a")
(blue . "#1f2c3f")
- (selected-normal-foreground . "@foreground")
- (normal-foreground . "@foreground")
- (alternate-normal-background . "@background")
- (selected-urgent-foreground . "@foreground")
- (urgent-foreground . "@foreground")
- (alternate-urgent-background . "@background")
+ (selected-normal-foreground . "@text-color")
+ (normal-foreground . "@text-color")
+ (alternate-normal-background . "@background-color")
+ (selected-urgent-foreground . "@text-color")
+ (urgent-foreground . "@text-color")
+ (alternate-urgent-background . "@background-color")
(active-foreground . "@text-color")
- (selected-active-foreground . "@foreground")
- (alternate-normal-foreground . "@foreground")
+ (selected-active-foreground . "@text-color")
+ (alternate-normal-foreground . "@text-color")
(alternate-active-background . "@blue")
- (bordercolor . "@foreground")
- (normal-background . "@background")
+ (bordercolor . "@text-color")
+ (normal-background . "@background-color")
(selected-normal-background . "@blue")
(separatorcolor . "@orange")
(spacing . 2)
(urgent-background . "@red")
- (alternate-urgent-foreground . "@foreground")
+ (alternate-urgent-foreground . "@text-color")
(selected-urgent-background . "@red")
- (alternate-active-foreground . "@foreground")
+ (alternate-active-foreground . "@text-color")
(selected-active-background . "@blue")
(active-background . "@red")
(font . "Fantasque Sans Mono 14")))
(window ((border . 0)
- (text-color . "@foreground")
+ (text-color . "@text-color")
(background-color . "rgba(0, 0, 0, 0%)")
(padding . 5)
(text-color . "@bordercolor")
- (background-color . "@background")))
+ (background-color . "@background-color")))
(mainbox ((border . 0)
(padding . 0)))
(message ((border . "1px dash 0px 0px")
(text-color . "@separatorcolor")
(padding . "2px 0px 0px")))
- (textbox ((text-color . "@foreground")))
+ (textbox ((text-color . "@text-color")))
(listview ((fixed-height . 0)
(border . "2px 0px 0px")
(padding . "2px 0px 0px")
@@ -141,17 +141,12 @@
(element ((border . 0)
(children "element-icon" "element-text")
(spacing . "5px")))
- (element-text
- element-icon ((background-color . "inherit")
- (text-color . "inherit")))
(element.normal.normal ((text-color . "@normal-foreground")
(background-color . "@normal-background")))
(element.normal.urgent ((text-color . "@urgent-foreground")
(background-color . "@urgent-background")))
(element.normal.active ((text-color . "@active-foreground")
(background-color . "@active-background")))
- (element.selected.normal ((text-color . "@selected-normal-foreground")
- (background-color . "@selected-normal-background")))
(element.selected.urgent ((text-color . "@selected-urgent-foreground")
(background-color . "@selected-urgent-background")))
(element.selected.active ((text-color . "@selected-active-foreground")
@@ -168,7 +163,7 @@
(inputbar ((spacing . 0)
(border . "0px")
(children "prompt" "textbox-prompt-colon" "entry" "case-indicator")))
- (#{button normal}# ((text-color . "@foreground")))
+ (#{button normal}# ((text-color . "@text-color")))
(text-prompt-color ((expand . #f)
(str . ":")
(margin . "0px 0.3em 0em 0em")
diff --git a/oni/home/services/rofi.scm b/oni/home/services/rofi.scm
index 6cf3928..83a5598 100644
--- a/oni/home/services/rofi.scm
+++ b/oni/home/services/rofi.scm
@@ -67,8 +67,10 @@
(object->string val))
((string? val)
(let ((color-match (regexp-exec color-regexp val)))
- (if (regexp-match? color-match)
- val (string-append "\"" val "\""))))
+ (if (or (string-prefix? "@" val)
+ (regexp-match? color-match))
+ val
+ (string-append "\"" val "\""))))
(else val)))
(define (format-rofi-config config)
@@ -117,7 +119,7 @@
(home-rofi-configuration-config conf))
;; Apply theme
(if (not (eq? (home-rofi-configuration-theme conf) '()))
- (list "\n@theme \"guix\"\n") '()))))
+ (list "\n@import \"guix\"\n") '()))))
("rofi/guix.rasi"
,(mixed-text-file
"guix.rasi"