From a0b84bf7dc2adbd8baba8fa9f30fc1fd114bf441 Mon Sep 17 00:00:00 2001 From: willifan Date: Mon, 3 Jun 2024 13:47:23 +0200 Subject: [PATCH] add media truncate --- eww/eww.yuck | 52 +++++++++++++++++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 17 deletions(-) diff --git a/eww/eww.yuck b/eww/eww.yuck index 8a34d18..77448e2 100644 --- a/eww/eww.yuck +++ b/eww/eww.yuck @@ -6,14 +6,20 @@ (defwidget time [] - (eventbox - :onclick `` - :class "smallBox" - :valign "center" - :height 20 - :width 70 - (label - :text "${formattime(EWW_TIME, "%H:%M:%S")}"))) + (box + :class "barbox" + :space-evenly false + :spacing 3 + (space) + (eventbox + :onclick `` + :class "smallBox" + :valign "center" + :height 20 + :width 70 + (label + :text "${formattime(EWW_TIME, "%H:%M:%S")}")) + (space))) ;; center @@ -106,18 +112,16 @@ :halign "end" :valign "center" :height 20 - (seperator) + (space) (box :class "smallBox" :height 20 :valign "center" - :space-evenly false - (space) (label :text {media.name} :tooltip {media.name} - :limit-width 40) - (space)))) + :truncate true)) + (space))) (defwidget processing [] (eventbox @@ -193,16 +197,30 @@ (defwidget start [] (box - :class "barbox" :orientation "h" :space-evenly false :height 30 :halign "start" :valign "center" :spacing 3 - (space) - (time) - (media) + (box + :class "barbox" + :orientation "h" + :space-evenly false + :height 30 + :halign "start" + :valign "center" + :spacing 3 + (time)) + (box + :class "barbox" + :orientation "h" + :space-evenly false + :height 30 + :halign "start" + :valign "center" + :spacing 3 + (media)) (space))) (defwidget center [monitor]