]> Freerunner's - dotfiles.git/commitdiff
waybar: some more tweaks
authorAndre Ramnitz <tux.rising@gmail.com>
Mon, 18 Nov 2024 22:56:09 +0000 (23:56 +0100)
committerAndre Ramnitz <tux.rising@gmail.com>
Mon, 18 Nov 2024 22:56:09 +0000 (23:56 +0100)
dot-config/waybar/config.jsonc
dot-config/waybar/style.css

index 9ba4dcb080369e70ed8fd489f61acf1faab3f186..fc6247366a122255297c617d0abc29e2ce732bd9 100644 (file)
   },
   "cpu": {
     //"format": "<span color='#efefef'>{usage:2}%</span> ",
-    "format": "{usage:2}%",
+    "format": "󰻠{usage:2}%",
     "on-click": "footclient -a popup btop -p 3",
     "interval": 1
   },
+  "custom/gpuusage": {
+    "exec": "cat /sys/class/hwmon/hwmon0/device/gpu_busy_percent",
+    "format": " {}%",
+    "return-type": "",
+    "interval": 1,
+    "max-length": 5
+  },
   "memory": {
     //"format": "<span color='#efefef'>{percentage:2}%</span> 󰳿",
     "format": "{percentage:2}%",
     "orientation": "horizontal",
     "modules": [
       "cpu",
+      "custom/gpuusage",
       "group/temps",
       "memory"
     ]
index 40a9f2b28adb227230d1874723aee2d91838e5d7..94c8408a414be63e170a3cf193fb49690a1b69bc 100644 (file)
@@ -86,6 +86,32 @@ tooltip label {
   color: @base00;
   transition: all 0.3s ease;
 }
+
+#window {
+  padding-left: 10px;
+  padding-right: 10px;
+  color: @base05;
+  background-color: alpha(@base04, 0.1);
+    border-radius: 0px 0px 4px 4px;
+    margin-top: 0px;
+    margin-bottom: 4px;
+    border-top: none;
+    border-left: 1px solid;
+    border-right: 1px solid;
+    border-bottom: 1px solid;
+    border-color: alpha(@base04, 0.4);
+}
+
+window#waybar {
+  border-top: none;
+  border-left: 1px solid @base00;
+  border-right: 1px solid @base00;
+  border-bottom: 1px solid @base00;
+  background-color: alpha(@base01, 0.92);
+  transition-property: background-color;
+  transition-duration: 0.5s;
+  /*background: linear-gradient(180deg, rgba(21,21,21,1) 0%, rgba(21,21,21,1) 45%, rgba(32,32,32,0.3) 100%);*/
+}
 /* ------------------------------------ workspaces end ------------------------------ */
 
 /* ------------------------------------ modules individual config  ------------------------------- */
@@ -139,32 +165,6 @@ tooltip label {
   border: none;
 }
 
-#window {
-  padding-left: 10px;
-  padding-right: 10px;
-  color: @base05;
-  background-color: alpha(@base04, 0.1);
-    border-radius: 0px 0px 4px 4px;
-    margin-top: 0px;
-    margin-bottom: 4px;
-    border-top: none;
-    border-left: 1px solid;
-    border-right: 1px solid;
-    border-bottom: 1px solid;
-    border-color: alpha(@base04, 0.4);
-}
-
-window#waybar {
-  border-top: none;
-  border-left: 1px solid @base00;
-  border-right: 1px solid @base00;
-  border-bottom: 1px solid @base00;
-  background-color: alpha(@base01, 0.92);
-  transition-property: background-color;
-  transition-duration: 0.5s;
-  /*background: linear-gradient(180deg, rgba(21,21,21,1) 0%, rgba(21,21,21,1) 45%, rgba(32,32,32,0.3) 100%);*/
-}
-
 #submap {
     font-weight: 500;
     padding-left: 6px;
@@ -197,6 +197,20 @@ window#waybar {
     border-bottom: 1px solid;
     border-color: alpha(@base0B, 0.4);
 }
+#custom-gpuusage {
+  padding-left: 6px;
+  padding-right: 6px;
+  color: @base0B;
+  background-color: alpha(@base0B, 0.1);
+    border-radius: 0px 0px 0px 0px;
+    margin-top: 0px;
+    margin-bottom: 4px;
+    border-top: none;
+    border-left: none;
+    border-right: none;
+    border-bottom: 1px solid;
+    border-color: alpha(@base0B, 0.4);
+}
 #temperature,
 #temperature#cpu,
 #temperature#chipset,
@@ -386,6 +400,7 @@ window#waybar {
 }
 
 #cpu:hover,
+#custom-gpuusage:hover,
 #memory:hover,
 #clock:hover,
 #custom-gammarelay-brightness:hover,