weather widget
This commit is contained in:
1 parent
44afecd7df
commit
54278273cb
14 files changed
+2688
-50
No files matched your search
+27
-47
@@ -3,55 +3,35 @@
|
||||
(deflisten music_position "scripts/music listen-position")
|
||||
(deflisten music_status "scripts/music listen-status")
|
||||
|
||||
(defwidget music_progress_widget []
|
||||
(box
|
||||
:class "music_progress_box"
|
||||
:halign "center"
|
||||
:space-evenly false
|
||||
(box
|
||||
:state "progress"
|
||||
(scale
|
||||
:onscroll "playerctl position {}"
|
||||
:min 0
|
||||
:max "${music_metadata.length}"
|
||||
:active true
|
||||
:hexpand true
|
||||
:vexpand true
|
||||
:value "${music_position.position}"
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
; Music
|
||||
(defwidget music []
|
||||
(box :class "genwin" :orientation "h" :space-evenly "false" :vexpand "false" :hexpand "false"
|
||||
(box :class "album_art" :vexpand "false" :hexpand "false" :style "background-image: url('${music_metadata.arturl}');")
|
||||
(box :orientation "v" :spacing 20 :space-evenly "false" :vexpand "false" :hexpand "false"
|
||||
(label :halign "center" :class "song" :wrap "true" :limit-width 20 :text "${music_metadata.title}")
|
||||
(label :halign "center" :class "artist" :wrap "true" :limit-width 15 :text "${music_metadata.artist}")
|
||||
(box :orientation "h" :spacing 20 :halign "center" :space-evenly "true" :vexpand "false" :hexpand "false"
|
||||
(button :class "btn_prev" :onclick "playerctl previous" "")
|
||||
(button :class "btn_play" :onclick "playerctl play-pause" {"${music_status.status}" == "Playing" ? "" : ""})
|
||||
(button :class "btn_next" :onclick "playerctl next" "")
|
||||
)
|
||||
(box :class "music_bar" :halign "center" :state "progress"
|
||||
(scale
|
||||
:onscroll "playerctl position {}"
|
||||
:onclick "playerctl position {}"
|
||||
:min 0
|
||||
:max "${music_metadata.length}"
|
||||
:active true
|
||||
:hexpand true
|
||||
:vexpand true
|
||||
:value "${music_position.position}"
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(defwidget music []
|
||||
(box :class "genwin" :orientation "h" :space-evenly "false" :vexpand "false" :hexpand "false"
|
||||
(box :class "album_art" :vexpand "false" :hexpand "false" :style "background-image: url('${music_metadata.arturl}');")
|
||||
(box :orientation "v" :spacing 20 :space-evenly "false" :vexpand "false" :hexpand "false"
|
||||
(label :halign "center" :class "song" :wrap "true" :limit-width 20 :text "${music_metadata.title}")
|
||||
(label :halign "center" :class "artist" :wrap "true" :limit-width 15 :text "${music_metadata.artist}")
|
||||
(box :orientation "h" :spacing 20 :halign "center" :space-evenly "true" :vexpand "false" :hexpand "false"
|
||||
(button :class "btn_prev" :onclick "playerctl previous" "")
|
||||
(button :class "btn_play" :onclick "playerctl play-pause" {"${music_status.status}" == "Playing" ? "" : ""})
|
||||
(button :class "btn_next" :onclick "playerctl next" "")
|
||||
)
|
||||
(box :class "music_bar" :halign "center" :state "progress"
|
||||
(scale
|
||||
:onscroll "playerctl position {}"
|
||||
:onclick "playerctl position {}"
|
||||
:min 0
|
||||
:max "${music_metadata.length}"
|
||||
:active true
|
||||
:hexpand true
|
||||
:vexpand true
|
||||
:value "${music_position.position}"
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
; music
|
||||
(defwindow music :stacking "fg" :focusable "false" :screen 1 :monitor 0
|
||||
:geometry (geometry :x 100 :y 100 :width 610 :height 280)
|
||||
(music))
|
||||
:geometry (geometry :x 100 :y 100 :width 610 :height 280)
|
||||
(music))
|
||||
Reference in new issue
Block a user