From 0590bcc89f52cf80a73f5ef404e8ac859567e2a8 Mon Sep 17 00:00:00 2001 From: mpuchstein Date: Sat, 8 Mar 2025 19:35:19 +0100 Subject: [PATCH] integrated vikingowls settings --- .config/eww/widgets/hypr_activewindow.scss | 9 +--- .config/eww/widgets/hypr_activewindow.yuck | 10 ++-- .config/eww/widgets/hypr_workspaces.scss | 50 +++++++++++++------- .config/eww/widgets/hypr_workspaces.yuck | 11 +++-- .config/eww/widgets/sysmon.scss | 55 +++++++++++++++------- .config/eww/widgets/sysmon.yuck | 30 ++++++------ 6 files changed, 99 insertions(+), 66 deletions(-) diff --git a/.config/eww/widgets/hypr_activewindow.scss b/.config/eww/widgets/hypr_activewindow.scss index f3295dd..b80c64c 100644 --- a/.config/eww/widgets/hypr_activewindow.scss +++ b/.config/eww/widgets/hypr_activewindow.scss @@ -1,14 +1,9 @@ .activewindow{ background: lightgreen; color: black; - + &--xwayland{ - background: red; - color: black; - } - - &--tooltip{ - background: darkgrey; + background: maroon; color: white; } } diff --git a/.config/eww/widgets/hypr_activewindow.yuck b/.config/eww/widgets/hypr_activewindow.yuck index d2d6884..67ebb1c 100644 --- a/.config/eww/widgets/hypr_activewindow.yuck +++ b/.config/eww/widgets/hypr_activewindow.yuck @@ -1,4 +1,4 @@ -(deflisten activewindow :initial "..." "RUST_BACKTRACE=1 hyprman -a 2>>/tmp/eww_hyprman_activewindow.log") +(deflisten activewindow :initial "..." "hyprman -a 2>>/tmp/eww_hyprman_activewindow.log") (defvar windowIcons `{ @@ -15,20 +15,18 @@ (defwidget windowIcon [] (image - :limit-width 10 :icon-size: 12 :icon {activewindow.class})) (defwidget hypr_active_window [] (tooltip - (label :class "activewindow--tooltip" :text {activewindow.title}) + (label :text {activewindow.title}) (box :class "activewindow${activewindow.xwayland == true ? '--xwayland' : ''}" :halign "left" :valign "center" - :spacing 1 + :spacing 3 (label :limit-width 25 :unindent true - :text "${activewindow.class}")))) - + :text "${windowIcons[activewindow.class] ?: windowIcons['generic']} ${activewindow.class}")))) diff --git a/.config/eww/widgets/hypr_workspaces.scss b/.config/eww/widgets/hypr_workspaces.scss index 7278b04..91eb0ed 100644 --- a/.config/eww/widgets/hypr_workspaces.scss +++ b/.config/eww/widgets/hypr_workspaces.scss @@ -1,19 +1,35 @@ -.workspacecontainer{ - background: orange; -} +.workspaces { + /* Green */ + $light: #bad012; + $dark: #53730a; + + /* Orange */ + //$light: #fde10e; + //$dark: #ff6520; + + background: $dark; + padding: 3px 1rem; + + &--ws { + border-radius: 50%; + font-family: 'Symbols Nerd Font Mono'; + border: 1px solid blue; + color: black; -.workspace{ - border-radius: 1rem 1rem; - font-family: 'Symbols Nerd Font Mono'; - font-size: 16px; - border: 1px solid blue; - color: black; -} - -.wsactive{ - background: red; -} - -.wsinactive{ - background: yellow; + &--label { + font-size: 0.7rem; + } + + &--active { + background: $light; + color: $dark; + border-color: $light; + } + + &--inactive { + background: $dark; + color: $dark; + border-color: $light; + } + } } diff --git a/.config/eww/widgets/hypr_workspaces.yuck b/.config/eww/widgets/hypr_workspaces.yuck index efe031c..2dbdff1 100644 --- a/.config/eww/widgets/hypr_workspaces.yuck +++ b/.config/eww/widgets/hypr_workspaces.yuck @@ -8,18 +8,19 @@ (defwidget hypr_workspaces [] (box - :class "workspacecontainer" + :class "workspaces" :space-evenly false :spacing 3 (for workspace in workspaces (eventbox - :width 20 :height 20 + :width 20 :onclick "hyprctl dispatch workspace ${workspace.id}" + :cursor "pointer" :tooltip "${workspace.name}" - :class "workspace ${workspace.active == true ? 'wsactive' : 'wsinactive'}" + :class "workspaces--ws ${workspace.active == true ? 'workspaces--ws--active' : 'workspaces--ws--inactive'}" (label - :xalign 0 + :class "workspaces--ws--label" + :xalign 0.2 :yalign 0.5 - :limit-width 1 :text "${workspace.windows > 0 ? workspaceIcons.full : workspaceIcons.empty}"))))) diff --git a/.config/eww/widgets/sysmon.scss b/.config/eww/widgets/sysmon.scss index e989ed5..a836b3f 100644 --- a/.config/eww/widgets/sysmon.scss +++ b/.config/eww/widgets/sysmon.scss @@ -1,19 +1,42 @@ .sysmon{ - background: darkred; + * { + border-radius: 0; + } + + $border-middle: 1px solid black; + + background: transparent; color: black; -} -.danger{ - color: red -} -.ram{ - background: tan; -} -.disk{ - background: mediumturquoise; -} -.cpu{ - background: lightgreen; -} -.net{ - background: plum; + + .first { + border-radius: 1.5rem 0 0 1rem; + border-right: $border-middle; + } + + .middle { + border-right: $border-middle; + } + + .last { + border-radius: 0 1rem 1.5rem 0; + } + .danger{ + color: red + } + + .ram{ + background: tan; + } + + .disk{ + background: mediumturquoise; + } + + .cpu{ + background: lightgreen; + } + + .net{ + background: plum; + } } diff --git a/.config/eww/widgets/sysmon.yuck b/.config/eww/widgets/sysmon.yuck index c329a32..3329081 100644 --- a/.config/eww/widgets/sysmon.yuck +++ b/.config/eww/widgets/sysmon.yuck @@ -4,27 +4,27 @@ (box :class 'sysmon' :space-evenly false - :spacing 1 - (cpu) - (ram) - (disk) - (net))) + :spacing 0 + (cpu :class "first") + (ram :class "middle") + (disk :class "middle") + (net :class "last"))) -(defwidget ram [] +(defwidget ram [class] (tooltip - :class 'ram ${EWW_RAM.used_mem_perc > 90 ? 'danger' : ''}' + :class 'ram ${EWW_RAM.used_mem_perc > 90 ? 'danger' : ''} ${class}' (label :text " ${round(EWW_RAM.free_swap/1000000000, 2)} GB/${round(EWW_RAM.total_swap/1000000000, 2)} GB") (label :text " ${round(EWW_RAM.used_mem/1000000000, 2)} GB/${round(EWW_RAM.total_mem/1000000000, 2)} GB"))) -(defwidget disk [] +(defwidget disk [class] (tooltip - :class 'disk ${EWW_DISK["/"].used_perc > 90 ? 'danger' : ''}' + :class 'disk ${EWW_DISK["/"].used_perc > 90 ? 'danger' : ''} ${class}' (label :text " ${round(EWW_DISK["/"].free/1000000000, 2)} GB /${round(EWW_DISK["/"].total/1000000000, 2)} GB") (label :text " ${round(EWW_DISK["/"].used_perc,2)}%"))) -(defwidget cpu [] +(defwidget cpu [class] (tooltip - :class 'cpu' + :class 'cpu ${class}' (box :orientation "vertical" (for cpu in {EWW_CPU.cores} (box @@ -42,10 +42,10 @@ (label :text "${cpu.freq} Hz ${cpu.usage}%")))) (label :text " ${round(EWW_CPU.avg, 2)}%"))) -(defwidget net [] +(defwidget net [class] (box - :class 'net' + :class 'net ${class}' :space-evenly false (label :text "") - (label :text " ${round(EWW_NET.enp34s0.NET_UP * 8 / 1000000, 2)} Mbit") - (label :text " ${round(EWW_NET.enp34s0.NET_DOWN * 8 / 1000000, 2)} Mbit"))) + (label :text " ${round(EWW_NET[netiface].NET_UP * 8 / 1000000, 2)} Mbit") + (label :text " ${round(EWW_NET[netiface].NET_DOWN * 8 / 1000000, 2)} Mbit")))