mirror of
https://github.com/elkowar/dots-of-war.git
synced 2024-11-06 11:22:23 +00:00
bar stuff
This commit is contained in:
parent
b6444af068
commit
de8bad20ec
2 changed files with 25 additions and 20 deletions
|
@ -89,7 +89,7 @@ window {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
.music-popup {
|
.music_popup {
|
||||||
all: unset;
|
all: unset;
|
||||||
background-color: #1d2021;
|
background-color: #1d2021;
|
||||||
padding: 0px 20px;
|
padding: 0px 20px;
|
||||||
|
|
|
@ -5,10 +5,10 @@
|
||||||
(top :screen screen))
|
(top :screen screen))
|
||||||
(box :valign "center"
|
(box :valign "center"
|
||||||
:class "middle"
|
:class "middle"
|
||||||
(middle))
|
(middle :screen screen))
|
||||||
(box :valign "end"
|
(box :valign "end"
|
||||||
:class "segment-bottom"
|
:class "segment-bottom"
|
||||||
(bottom))))
|
(bottom :screen screen))))
|
||||||
|
|
||||||
(defwidget top []
|
(defwidget top []
|
||||||
(workspaces :wsp_yuck {screen == 0 ? workspaces_0_yuck : screen == 1 ? workspaces_1_yuck : workspaces_2_yuck}))
|
(workspaces :wsp_yuck {screen == 0 ? workspaces_0_yuck : screen == 1 ? workspaces_1_yuck : workspaces_2_yuck}))
|
||||||
|
@ -22,13 +22,14 @@
|
||||||
:class "time"
|
:class "time"
|
||||||
hour min sec))
|
hour min sec))
|
||||||
|
|
||||||
(defwidget bottom []
|
(defwidget bottom [screen ]
|
||||||
(box :orientation "v"
|
(box :orientation "v"
|
||||||
:valign "end"
|
:valign "end"
|
||||||
:space-evenly true
|
:space-evenly true
|
||||||
:spacing "5"
|
:spacing "5"
|
||||||
(box :class "metric" :orientation "v"
|
(box :class "metric" :orientation "v"
|
||||||
(button :onclick "eww -c /home/leon/.config/eww-bar open --toggle music-popup" "")
|
;(button :onclick "eww -c /home/leon/.config/eww-bar open --toggle music_popup --screen ${screen}" )
|
||||||
|
""
|
||||||
(music-button))
|
(music-button))
|
||||||
(volume)
|
(volume)
|
||||||
(box :class "metric" :orientation "v"
|
(box :class "metric" :orientation "v"
|
||||||
|
@ -52,6 +53,7 @@
|
||||||
:orientation "v"
|
:orientation "v"
|
||||||
:space-evenly false
|
:space-evenly false
|
||||||
:valign "fill"
|
:valign "fill"
|
||||||
|
|
||||||
:vexpand false
|
:vexpand false
|
||||||
(scale :orientation "h"
|
(scale :orientation "h"
|
||||||
:min 0
|
:min 0
|
||||||
|
@ -62,9 +64,11 @@
|
||||||
:valign "fill"
|
:valign "fill"
|
||||||
:vexpand true
|
:vexpand true
|
||||||
(button :onclick "./audio.sh toggle"
|
(button :onclick "./audio.sh toggle"
|
||||||
|
:onscroll "notify-send test {}; if [ '{}' == 'up' ]; then pamixer -i 5; else pamixer -d 5; fi"
|
||||||
(label :style "font-size: 1.2em; font-family: DejaVuSansMono Nerd Font Mono"
|
(label :style "font-size: 1.2em; font-family: DejaVuSansMono Nerd Font Mono"
|
||||||
:text audio_sink))
|
:text audio_sink))
|
||||||
(button :onclick "pavucontrol &"
|
(button :onclick "pavucontrol &"
|
||||||
|
:onscroll "if [ '{}' == 'up' ]; then pamixer -i 5; else pamixer -d 5; fi"
|
||||||
"${volume}%"))))
|
"${volume}%"))))
|
||||||
|
|
||||||
|
|
||||||
|
@ -79,7 +83,6 @@
|
||||||
day_word day month year))
|
day_word day month year))
|
||||||
|
|
||||||
; TODO make this not hacky
|
; TODO make this not hacky
|
||||||
|
|
||||||
(defvar audio_sink "")
|
(defvar audio_sink "")
|
||||||
|
|
||||||
(deflisten volume :initial "0" "./audio.sh volume")
|
(deflisten volume :initial "0" "./audio.sh volume")
|
||||||
|
@ -117,17 +120,19 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defwidget music-popup []
|
;(defwidget music-popup []
|
||||||
(box :class "music-popup"
|
;(if-else :cond {music_data.status == "Stopped" || music_data.status == ""}
|
||||||
:orientation "h"
|
;"No music playing"
|
||||||
:space-evenly false
|
;(box :orientation "h"
|
||||||
:spacing 10
|
;:valign "fill"
|
||||||
(button :onclick "playerctl previous" "⏮")
|
;:space-evenly false
|
||||||
"${music_data.artist} - ${music_data.title}"
|
;:spacing 10
|
||||||
(button :onclick "playerctl next" "⏭"))
|
;(button :onclick "playerctl previous" "⏮")
|
||||||
)
|
;"${music_data.artist} - ${music_data.title}"
|
||||||
|
;(button :onclick "playerctl next" "⏭"))))
|
||||||
|
|
||||||
(defwindow music-popup
|
;(defwindow music_popup
|
||||||
:monitor 1
|
;:monitor 1
|
||||||
:geometry (geometry :x "30px" :y "70%" :height "65px")
|
;:anchor "bottom left"
|
||||||
(music-popup))
|
;:geometry (geometry :x "30px" :y "10px" :height "65px")
|
||||||
|
;(music-popup))
|
||||||
|
|
Loading…
Reference in a new issue