✨ feat(ui): add new applet icons for better visual representation

This commit is contained in:
sankalp committed 2025-08-01 01:02:07 +05:45
1 parent db44d4e329
commit 18f83a2b4a
34 files changed
+121 -111

No files matched your search

File renamed without changes.

Before

Width:  |  Height:  |  Size: 235 B

After

Width:  |  Height:  |  Size: 235 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 312 B

After

Width:  |  Height:  |  Size: 312 B

@@ -0,0 +1,4 @@
<svg viewBox="-10 -10 45 45" width="28" height="28" stroke="#fff" stroke-width="2" fill="#aaa" stroke-linecap="round" stroke-linejoin="round" class="css-i6dzq1">
<circle cx="12" cy="12" r="18" stroke="#aaa" stroke-width="1.5" fill="#aaa"></circle>
<polyline points="6.5 6.5 17.5 17.5 12 23 12 1 17.5 6.5 6.5 17.5"></polyline>
</svg>

After

Width:  |  Height:  |  Size: 334 B

@@ -0,0 +1,4 @@
<svg viewBox="-10 -10 45 45" width="28" height="28" stroke="#fff" stroke-width="2" fill="#2369ff" stroke-linecap="round" stroke-linejoin="round" class="css-i6dzq1">
<circle cx="12" cy="12" r="18" stroke="#2369ff" stroke-width="1.5" fill="#2369ff"></circle>
<polyline points="6.5 6.5 17.5 17.5 12 23 12 1 17.5 6.5 6.5 17.5"></polyline>
</svg>

After

Width:  |  Height:  |  Size: 343 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 770 B

After

Width:  |  Height:  |  Size: 770 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 334 B

After

Width:  |  Height:  |  Size: 334 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 343 B

After

Width:  |  Height:  |  Size: 343 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 347 B

After

Width:  |  Height:  |  Size: 347 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 519 B

After

Width:  |  Height:  |  Size: 519 B

+10
View File
@@ -0,0 +1,10 @@
<svg viewBox="-10 -10 45 45" width="28" height="28" stroke="#fff" stroke-width="2" fill="#aaa" stroke-linecap="round" stroke-linejoin="round" class="css-i6dzq1">
<circle cx="12" cy="12" r="18" stroke="#aaa" stroke-width="1.5" fill="#aaa"></circle>
<line x1="1" y1="1" x2="23" y2="23"></line>
<path d="M16.72 11.06A10.94 10.94 0 0 1 19 12.55"></path>
<path d="M5 12.55a10.94 10.94 0 0 1 5.17-2.39"></path>
<path d="M10.71 5.05A16 16 0 0 1 22.58 9"></path>
<path d="M1.42 9a15.91 15.91 0 0 1 4.7-2.88"></path>
<path d="M8.53 16.11a6 6 0 0 1 6.95 0"></path>
<line x1="12" y1="20" x2="12.01" y2="20"></line>
</svg>

After

Width:  |  Height:  |  Size: 618 B

+7
View File
@@ -0,0 +1,7 @@
<svg viewBox="-10 -10 45 45" width="28" height="28" stroke="#fff" stroke-width="2" fill="#2369ff" stroke-linecap="round" stroke-linejoin="round" class="css-i6dzq1">
<circle cx="12" cy="12" r="18" stroke="#2369ff" stroke-width="1.5" fill="#2369ff"></circle>
<path d="M5 12.55a11 11 0 0 1 14.08 0"></path>
<path d="M1.42 9a16 16 0 0 1 21.16 0"></path>
<path d="M8.53 16.11a6 6 0 0 1 6.95 0"></path>
<line x1="12" y1="20" x2="12.01" y2="20"></line>
</svg>

After

Width:  |  Height:  |  Size: 457 B

-7
View File
@@ -1,7 +0,0 @@
<svg viewBox="0 0 32 32" width="24" height="24" version="1.1" xmlns="http://www.w3.org/2000/svg">
<style id="current-color-scheme" type="text/css">.ColorScheme-Text {
color:#fff;
}</style>
<path class="ColorScheme-Text" d="m4.5 8c-2.493 0-4.5 2.007-4.5 4.5v7c0 2.493 2.007 4.5 4.5 4.5h20c2.493 0 4.5-2.007 4.5-4.5v-7c0-2.493-2.007-4.5-4.5-4.5zm0 1h20c1.939 0 3.5 1.561 3.5 3.5v7c0 1.939-1.561 3.5-3.5 3.5h-20c-1.939 0-3.5-1.561-3.5-3.5v-7c0-1.939 1.561-3.5 3.5-3.5zm25.5 4.5v5a2 2.5 0 0 0 2-2.5 2 2.5 0 0 0-2-2.5z" fill="currentColor" opacity=".45"/>
<rect class="ColorScheme-Text" x="2" y="10" width="25" height="12" rx="2.5" ry="2.5" fill="currentColor"/>
</svg>

Before

Width:  |  Height:  |  Size: 687 B

@@ -1,8 +0,0 @@
<svg width="32" height="32" version="1.1" xmlns="http://www.w3.org/2000/svg">
<style id="current-color-scheme" type="text/css">.ColorScheme-Text {
color:#dedede;
}</style>
<path class="ColorScheme-Text" d="m16.25 4.9375c-0.0985-1.54e-4 -0.19605 0.01909-0.28711 0.05664-0.28036 0.1162-0.46307 0.38988-0.46289 0.69336v8.1847l-5.2422-4.8223c-0.14642-0.13464-0.34032-0.2056-0.53906-0.19726-0.19881 0.0077-0.3864 0.09416-0.52148 0.24023-0.2808 0.30514-0.26068 0.78023 0.0449 1.0605l6.2578 5.7578v0.17969l-6.2578 5.7559c-0.3043 0.28012-0.32438 0.75371-0.0449 1.0586 0.28031 0.30558 0.7554 0.32571 1.0605 0.04492l5.2422-4.8223v8.1845c-1e-3 0.66959 0.80849 1.0054 1.2812 0.53125l6-5.3134c0.30283-0.3033 0.29038-0.79824-0.0273-1.0859l-4.8907-4.4453 4.8906-4.4453c0.31768-0.2877 0.33013-0.78264 0.0273-1.0859l-6-5.3116c-0.14102-0.14052-0.33213-0.21922-0.53121-0.21875zm0.75 2.5625 4.1621 3.4737-4.1621 3.7852zm0 9.7394 4.1621 3.7852-4.1621 3.4755z" fill="currentColor"/>
<path class="ColorScheme-Text" d="m3.0002 15.032c-0.55228 0-1 0.44772-1 1s0.44772 1 1 1 1-0.44772 1-1-0.44772-1-1-1zm4 0c-0.55228 0-1 0.44772-1 1s0.44772 1 1 1 1-0.44772 1-1-0.44772-1-1-1z" fill="currentColor"/>
<path class="ColorScheme-Text" d="m25 15.032c-0.55228 0-1 0.44772-1 1s0.44772 1 1 1 1-0.44772 1-1-0.44772-1-1-1zm4 0c-0.55228 0-1 0.44772-1 1s0.44772 1 1 1 1-0.44772 1-1-0.44772-1-1-1z" fill="currentColor"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.4 KiB

-7
View File
@@ -1,7 +0,0 @@
<svg width="32" height="32" version="1.1" xmlns="http://www.w3.org/2000/svg">
<style id="current-color-scheme" type="text/css">.ColorScheme-Text {
color:#dedede;
}</style>
<path class="ColorScheme-Text" d="m16.25 4.9375c-0.0985-1.54e-4 -0.19605 0.01909-0.28711 0.05664-0.28036 0.1162-0.46307 0.38988-0.46289 0.69336v8.1847l-5.2422-4.8223c-0.14642-0.13464-0.34032-0.2056-0.53906-0.19726-0.19881 0.0077-0.3864 0.09416-0.52148 0.24023-0.2808 0.30514-0.26068 0.78023 0.0449 1.0605l6.2578 5.7578v0.17969l-6.2578 5.7559c-0.3043 0.28012-0.32438 0.75371-0.0449 1.0586 0.28031 0.30558 0.7554 0.32571 1.0605 0.04492l5.2422-4.8223v8.1845c-1e-3 0.66959 0.80849 1.0054 1.2812 0.53125l6-5.3134c0.30283-0.3033 0.29038-0.79824-0.0273-1.0859l-4.8907-4.4453 4.8906-4.4453c0.31768-0.2877 0.33013-0.78264 0.0273-1.0859l-6-5.3116c-0.14102-0.14052-0.33213-0.21922-0.53121-0.21875zm0.75 2.5625 4.1621 3.4737-4.1621 3.7852zm0 9.7394 4.1621 3.7852-4.1621 3.4755z" fill="currentColor" opacity=".35"/>
<rect class="ColorScheme-Text" transform="rotate(45)" x="6.6274" y="-.75" width="32" height="1.5" rx=".75" ry=".75" fill="currentColor"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.1 KiB

-6
View File
@@ -1,6 +0,0 @@
<svg width="32" height="32" version="1.1" xmlns="http://www.w3.org/2000/svg">
<style id="current-color-scheme" type="text/css">.ColorScheme-Text {
color:#dedede;
}</style>
<path class="ColorScheme-Text" d="m16.25 4.9375c-0.0985-1.54e-4 -0.19605 0.01909-0.28711 0.05664-0.28036 0.1162-0.46307 0.38988-0.46289 0.69336v8.1847l-5.2422-4.8223c-0.14642-0.13464-0.34032-0.2056-0.53906-0.19726-0.19881 0.0077-0.3864 0.09416-0.52148 0.24023-0.2808 0.30514-0.26068 0.78023 0.0449 1.0605l6.2578 5.7578v0.17969l-6.2578 5.7559c-0.3043 0.28012-0.32438 0.75371-0.0449 1.0586 0.28031 0.30558 0.7554 0.32571 1.0605 0.04492l5.2422-4.8223v8.1845c-1e-3 0.66959 0.80849 1.0054 1.2812 0.53125l6-5.3134c0.30283-0.3033 0.29038-0.79824-0.0273-1.0859l-4.8907-4.4453 4.8906-4.4453c0.31768-0.2877 0.33013-0.78264 0.0273-1.0859l-6-5.3116c-0.14102-0.14052-0.33213-0.21922-0.53121-0.21875zm0.75 2.5625 4.1621 3.4737-4.1621 3.7852zm0 9.7394 4.1621 3.7852-4.1621 3.4755z" fill="currentColor"/>
</svg>

Before

Width:  |  Height:  |  Size: 984 B

+6
View File
@@ -0,0 +1,6 @@
<svg width="16" height="16" version="1.1" xmlns="http://www.w3.org/2000/svg">
<defs>
<style id="current-color-scheme" type="text/css"/>
</defs>
<path d="m7.75 2v2.5h0.5v-2.5zm-3.8965 1.5-0.35352 0.35352 1.7676 1.7676 0.35352-0.35352zm8.1465 0-1.7676 1.7676 0.35352 0.35352 1.7676-1.7676zm-4 1.5a3 3 0 0 0-3 3 3 3 0 0 0 3 3 3 3 0 0 0 3-3 3 3 0 0 0-3-3zm0.011719 0.98242a2.0292 2.0292 0 0 1 2.0293 2.0293 2.0292 2.0292 0 0 1-2.0293 2.0293 2.0292 2.0292 0 0 1-2.0293-2.0293 2.0292 2.0292 0 0 1 2.0293-2.0293zm-6.0117 1.7676v0.5h2.5v-0.5zm9.5 0v0.5h2.5v-0.5zm-6.2324 2.6289-1.7676 1.7676 0.35352 0.35352 1.7676-1.7676zm5.4648 0-0.35352 0.35352 1.7676 1.7676 0.35352-0.35352zm-2.9824 1.1211v2.5h0.5v-2.5z" fill="#f2f2f2" style="paint-order:fill markers stroke"/>
</svg>

After

Width:  |  Height:  |  Size: 770 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

-3
View File
@@ -1,3 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<circle cx="12" cy="12" r="6" fill="#aaa" />
</svg>

Before

Width:  |  Height:  |  Size: 138 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 854 B

After

Width:  |  Height:  |  Size: 854 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 515 B

After

Width:  |  Height:  |  Size: 515 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 515 B

After

Width:  |  Height:  |  Size: 515 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 874 B

After

Width:  |  Height:  |  Size: 874 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

File renamed without changes.

Before

Width:  |  Height:  |  Size: 560 B

After

Width:  |  Height:  |  Size: 560 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 261 B

After

Width:  |  Height:  |  Size: 261 B

-12
View File
@@ -1,12 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" width="32" height="32">
<style type="text/css" id="current-color-scheme">
.ColorScheme-Text {
color:#dedede;
}
</style>
<g id="system-search" transform="translate(0 -32) translate(-22,32)">
<path id="path66" class="ColorScheme-Text" d="m35 4a9 9 0 0 0-9 9 9 9 0 0 0 9 9 9 9 0 0 0 5.994141-2.298828l8.298828 8.298828 0.707031-0.707031-8.300781-8.300782a9 9 0 0 0 2.300781-5.992187 9 9 0 0 0-9-9zm0 1a8 8 0 0 1 8 8 8 8 0 0 1-8 8 8 8 0 0 1-8-8 8 8 0 0 1 8-8z" fill="currentColor"/>
<path id="path68" d="m22 0v32h32v-32z" fill="none"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 997 B

File renamed without changes.

Before

Width:  |  Height:  |  Size: 820 B

After

Width:  |  Height:  |  Size: 820 B

+31 -25
View File
@@ -1,8 +1,13 @@
import re
import subprocess import subprocess
import re
import gi # type: ignore
from fabric.utils.helpers import get_relative_path from fabric.widgets.label import Label
from gi.repository import GdkPixbuf, Gtk # type: ignore from fabric.widgets.button import Button
from fabric.widgets.box import Box
from widgets.wayland import WaylandWindow as Window
from fabric.utils.helpers import exec_shell_command_async, get_relative_path
from gi.repository import Gtk, GdkPixbuf # type: ignore
def read_dmi(field): def read_dmi(field):
@@ -14,31 +19,32 @@ def read_dmi(field):
def get_gpu_name(): def get_gpu_name():
output = subprocess.check_output("lspci", text=True) try:
gpus = [] output = (
subprocess.check_output(
"lspci -nn | grep -i 'VGA compatible controller'", shell=True, text=True
)
.strip()
.split("\n")
)
for line in output.splitlines(): def clean(line):
if "VGA compatible controller" in line or "3D controller" in line: matches = re.findall(r"\[(.*?)\]", line)
parts = line.split(":", 2) if len(matches) >= 2:
if len(parts) < 3: return matches[1].strip()
continue desc = line.split(":", 2)[-1]
desc = parts[2].strip() return desc.replace("Corporation", "").strip()
desc = re.sub(r"\(rev .*?\)", "", desc).strip()
if "NVIDIA" in desc: for line in output:
match = re.search(r"\[(.*?)\]", desc) if any(vendor in line.lower() for vendor in ["nvidia", "amd", "radeon"]):
name = match.group(1) if match else desc return clean(line)
elif "Intel" in desc:
name = re.sub(r"Intel Corporation", "Intel", desc).strip()
elif "AMD" in desc or "ATI" in desc:
matches = re.findall(r"\[(.*?)\]", desc)
name = matches[1] if len(matches) > 1 else desc
else:
name = desc
gpus.append((name)) if output:
return clean(output[0])
return gpus[-1] return "Unknown GPU"
except Exception:
return "Unknown GPU"
class About(Gtk.Window): class About(Gtk.Window):
@@ -60,7 +66,7 @@ class About(Gtk.Window):
# Logo # Logo
logo_box = Gtk.Box(halign=Gtk.Align.CENTER, valign=Gtk.Align.CENTER) logo_box = Gtk.Box(halign=Gtk.Align.CENTER, valign=Gtk.Align.CENTER)
pixbuf = GdkPixbuf.Pixbuf.new_from_file_at_scale( pixbuf = GdkPixbuf.Pixbuf.new_from_file_at_scale(
get_relative_path("../config/assets/icons/imac.svg"), get_relative_path("../config/assets/icons/misc/imac.svg"),
158, 158,
108, 108,
preserve_aspect_ratio=True, preserve_aspect_ratio=True,
+33 -16
View File
@@ -113,17 +113,23 @@ class ModusControlCenter(Window):
self.has_bluetooth_open = False self.has_bluetooth_open = False
self.has_wifi_open = False self.has_wifi_open = False
self.bluetooth_svg = Image( self.bluetooth_svg = Svg(
name="bluetooth-icon", name="bluetooth-icon",
icon_name="bluetooth-symbolic", svg_file=get_relative_path(
size=24, "../../config/assets/icons/applets/bluetooth.svg"
style_classes="connected" if bluetooth != "disabled" else "", if bluetooth != "disabled"
else "../../config/assets/icons/applets/bluetooth-off.svg"
),
size=42,
) )
self.wifi_svg = Image( self.wifi_svg = Svg(
name="wifi-icon", name="wifi-icon",
icon_name="network-wireless-symbolic", svg_file=get_relative_path(
size=24, "../../config/assets/icons/applets/wifi.svg"
style_classes="connected" if wlan != "No Connection" else "", if wlan != "No Connection"
else "../../config/assets/icons/applets/wifi-off.svg"
),
size=46,
) )
self.bluetooth_widget = Button( self.bluetooth_widget = Button(
@@ -171,8 +177,9 @@ class ModusControlCenter(Window):
) )
self.focus_icon = Svg( self.focus_icon = Svg(
svg_file=get_relative_path("../../config/assets/icons/dnd-off.svg"), name="focus-icon",
size=24, svg_file=get_relative_path("../../config/assets/icons/applets/dnd-off.svg"),
size=46,
) )
self.focus_widget = Button( self.focus_widget = Button(
@@ -252,9 +259,9 @@ class ModusControlCenter(Window):
modus_service.dont_disturb = self.focus_mode modus_service.dont_disturb = self.focus_mode
self.focus_icon.set_from_file( self.focus_icon.set_from_file(
get_relative_path( get_relative_path(
"config/assets/icons/dnd.svg" "../../config/assets/icons/applets/dnd.svg"
if self.focus_mode if self.focus_mode
else "config/assets/icons/dnd-off.svg" else "../../config/assets/icons/applets/dnd-off.svg"
) )
) )
@@ -345,8 +352,14 @@ class ModusControlCenter(Window):
) )
def wlan_changed(self, _, wlan): def wlan_changed(self, _, wlan):
self.wifi_svg.set_from_file(
get_relative_path(
"../../config/assets/icons/applets/wifi.svg"
if wlan != "No Connection"
else "../../config/assets/icons/applets/wifi-off.svg"
)
)
if wlan != "No Connection": if wlan != "No Connection":
self.wifi_svg.set_property("style-classes", "connected")
if wlan.startswith("connected:"): if wlan.startswith("connected:"):
parts = wlan.split(":") parts = wlan.split(":")
if len(parts) >= 2: if len(parts) >= 2:
@@ -357,12 +370,17 @@ class ModusControlCenter(Window):
else: else:
GLib.idle_add(lambda: self.wlan_label.set_property("label", wlan)) GLib.idle_add(lambda: self.wlan_label.set_property("label", wlan))
else: else:
self.wifi_svg.set_property("style-classes", "")
GLib.idle_add(lambda: self.wlan_label.set_property("label", wlan)) GLib.idle_add(lambda: self.wlan_label.set_property("label", wlan))
def bluetooth_changed(self, _, bluetooth): def bluetooth_changed(self, _, bluetooth):
self.bluetooth_svg.set_from_file(
get_relative_path(
"../../config/assets/icons/applets/bluetooth.svg"
if bluetooth != "disabled"
else "../../config/assets/icons/applets/bluetooth-off.svg"
)
)
if bluetooth != "disabled": if bluetooth != "disabled":
self.bluetooth_svg.set_property("style-classes", "connected")
if bluetooth.startswith("connected:"): if bluetooth.startswith("connected:"):
parts = bluetooth.split(":") parts = bluetooth.split(":")
if len(parts) >= 2: if len(parts) >= 2:
@@ -375,7 +393,6 @@ class ModusControlCenter(Window):
else: else:
GLib.idle_add(lambda: self.bluetooth_label.set_property("label", "On")) GLib.idle_add(lambda: self.bluetooth_label.set_property("label", "On"))
else: else:
self.bluetooth_svg.set_property("style-classes", "")
GLib.idle_add(lambda: self.bluetooth_label.set_property("label", "Off")) GLib.idle_add(lambda: self.bluetooth_label.set_property("label", "Off"))
def audio_changed(self, *_): def audio_changed(self, *_):
+3 -3
View File
@@ -50,7 +50,7 @@ class BrightnessOSDContainer(Box):
orientation="h", orientation="h",
) )
self.osd_window_image = Svg( self.osd_window_image = Svg(
get_relative_path("../config/assets/icons/brightness.svg"), get_relative_path("../config/assets/icons/brightness/brightness.svg"),
size=(84, 150), size=(84, 150),
name="osd-image", name="osd-image",
h_align="center", h_align="center",
@@ -112,7 +112,7 @@ class AudioOSDContainer(Box):
orientation="h", orientation="h",
) )
self.osd_window_image = Svg( self.osd_window_image = Svg(
get_relative_path("../config/assets/icons/audio-volume.svg"), get_relative_path("../config/assets/icons/volume/audio-volume.svg"),
size=(64, 150), size=(64, 150),
name="osd-image", name="osd-image",
h_align="center", h_align="center",
@@ -253,7 +253,7 @@ class MicrophoneOSDContainer(Box):
) )
self.osd_window_image = Svg( self.osd_window_image = Svg(
get_relative_path("../config/assets/icons/microphone.svg"), get_relative_path("../config/assets/icons/mic/microphone.svg"),
size=(64, 150), size=(64, 150),
name="osd-image", name="osd-image",
h_align="center", h_align="center",
+16 -17
View File
@@ -3,9 +3,8 @@ from fabric.utils import get_relative_path
from fabric.widgets.box import Box from fabric.widgets.box import Box
from fabric.widgets.button import Button from fabric.widgets.button import Button
from fabric.widgets.svg import Svg from fabric.widgets.svg import Svg
from services.battery import Battery
from services.network import NetworkService from services.network import NetworkService
from services.battery import Battery
from utils.roam import modus_service from utils.roam import modus_service
@@ -17,7 +16,7 @@ class BluetoothIndicator(Box):
self.bt_icon = Svg( self.bt_icon = Svg(
name="bt-icon", name="bt-icon",
size=20, size=20,
svg_file=get_relative_path("../../../config/assets/icons/bluetooth.svg"), svg_file=get_relative_path("../../../config/assets/icons/applets/bluetooth-clear.svg"),
) )
self.bt_button = Button(name="bt-button", child=self.bt_icon) self.bt_button = Button(name="bt-button", child=self.bt_icon)
@@ -35,14 +34,14 @@ class BluetoothIndicator(Box):
def update_state(self): def update_state(self):
if not self.bluetooth.enabled: if not self.bluetooth.enabled:
self.bt_icon.set_from_file( self.bt_icon.set_from_file(
get_relative_path("../../../config/assets/icons/bluetooth-off.svg") get_relative_path("../../../config/assets/icons/applets/bluetooth-off-clear.svg")
) )
tooltip = "Bluetooth disabled" tooltip = "Bluetooth disabled"
else: else:
connected_devices = self.bluetooth.connected_devices connected_devices = self.bluetooth.connected_devices
if connected_devices: if connected_devices:
self.bt_icon.set_from_file( self.bt_icon.set_from_file(
get_relative_path("../../../config/assets/icons/bluetooth.svg") get_relative_path("../../../config/assets/icons/applets/bluetooth-clear.svg")
) )
if len(connected_devices) == 1: if len(connected_devices) == 1:
device = connected_devices[0] device = connected_devices[0]
@@ -53,7 +52,7 @@ class BluetoothIndicator(Box):
tooltip = f"Connected to {len(connected_devices)} devices" tooltip = f"Connected to {len(connected_devices)} devices"
else: else:
self.bt_icon.set_from_file( self.bt_icon.set_from_file(
get_relative_path("../../../config/assets/icons/bluetooth.svg") get_relative_path("../../../config/assets/icons/applets/bluetooth-clear.svg")
) )
tooltip = "No devices connected" tooltip = "No devices connected"
@@ -105,7 +104,7 @@ class NetworkIndicator(Box):
self.network_icon = Svg( self.network_icon = Svg(
name="network-icon", name="network-icon",
size=22, size=22,
svg_file=get_relative_path("../../../config/assets/icons/wifi.svg"), svg_file=get_relative_path("../../../config/assets/icons/applets/wifi-clear.svg"),
) )
self.network_button = Button(name="network-button", child=self.network_icon) self.network_button = Button(name="network-button", child=self.network_icon)
@@ -177,26 +176,26 @@ class NetworkIndicator(Box):
def update_state(self): def update_state(self):
primary_device = self.network_service.primary_device primary_device = self.network_service.primary_device
tooltip = "No network connection" tooltip = "No network connection"
icon_file = "wifi-off.svg" icon_file = "wifi-off-clear.svg"
if primary_device == "wifi" and self.network_service.wifi_device: if primary_device == "wifi" and self.network_service.wifi_device:
wifi = self.network_service.wifi_device wifi = self.network_service.wifi_device
if not wifi.enabled: if not wifi.enabled:
icon_file = "wifi-off.svg" icon_file = "wifi-off-clear.svg"
tooltip = "WiFi disabled" tooltip = "WiFi disabled"
elif wifi.internet == "activated": elif wifi.internet == "activated":
icon_file = "wifi.svg" icon_file = "wifi-clear.svg"
tooltip = f"Connected to {wifi.ssid}" tooltip = f"Connected to {wifi.ssid}"
if wifi.strength >= 0: if wifi.strength >= 0:
tooltip += f" ({wifi.strength}%)" tooltip += f" ({wifi.strength}%)"
elif wifi.internet == "activating": elif wifi.internet == "activating":
icon_file = "wifi.svg" icon_file = "wifi-clear.svg"
tooltip = f"Connecting to {wifi.ssid}..." tooltip = f"Connecting to {wifi.ssid}..."
elif wifi.internet in ["deactivating", "deactivated", "disconnected"]: elif wifi.internet in ["deactivating", "deactivated", "disconnected"]:
icon_file = "wifi-off.svg" icon_file = "wifi-off-clear.svg"
tooltip = "WiFi disconnected" tooltip = "WiFi disconnected"
else: else:
icon_file = "wifi-off.svg" icon_file = "wifi-off-clear.svg"
tooltip = "WiFi disconnected" tooltip = "WiFi disconnected"
elif primary_device == "wired" and self.network_service.ethernet_device: elif primary_device == "wired" and self.network_service.ethernet_device:
@@ -207,14 +206,14 @@ class NetworkIndicator(Box):
if hasattr(ethernet, "speed") and ethernet.speed > 0: if hasattr(ethernet, "speed") and ethernet.speed > 0:
tooltip += f" ({ethernet.speed} Mbps)" tooltip += f" ({ethernet.speed} Mbps)"
elif ethernet.internet == "activating": elif ethernet.internet == "activating":
icon_file = "wifi.svg" icon_file = "wifi-clear.svg"
tooltip = "Ethernet connecting..." tooltip = "Ethernet connecting..."
else: else:
icon_file = "wifi-off.svg" icon_file = "wifi-off-clear.svg"
tooltip = "Ethernet disconnected" tooltip = "Ethernet disconnected"
self.network_icon.set_from_file( self.network_icon.set_from_file(
get_relative_path(f"../../../config/assets/icons/{icon_file}") get_relative_path(f"../../../config/assets/icons/applets/{icon_file}")
) )
self.network_button.set_tooltip_text(tooltip) self.network_button.set_tooltip_text(tooltip)
@@ -228,7 +227,7 @@ class BatteryIndicator(Box):
self.battery_icon = Svg( self.battery_icon = Svg(
name="battery-icon", name="battery-icon",
size=22, size=22,
svg_file=get_relative_path("../../../config/assets/icons/battery.svg"), svg_file=get_relative_path("../../../config/assets/icons/battery/battery-100.svg"),
) )
self.battery_button = Button(name="battery-button", child=self.battery_icon) self.battery_button = Button(name="battery-button", child=self.battery_icon)
@@ -28,7 +28,7 @@ class RecordingIndicator(Button):
self.recording_icon = Svg( self.recording_icon = Svg(
name="indicators-icon", name="indicators-icon",
size=24, size=24,
svg_file=get_relative_path("../../../config/assets/icons/media-record.svg"), svg_file=get_relative_path("../../../config/assets/icons/misc/media-record.svg"),
) )
self.time_label = Label( self.time_label = Label(
name="recording-time-label", name="recording-time-label",
+6 -6
View File
@@ -43,7 +43,7 @@ class Panel(Window):
name="panel-button", name="panel-button",
child=Svg( child=Svg(
size=22, size=22,
svg_file=get_relative_path("../../config/assets/icons/logo.svg"), svg_file=get_relative_path("../../config/assets/icons/misc/logo.svg"),
), ),
on_clicked=lambda *_: self.menubar.show_system_dropdown(self.imac), on_clicked=lambda *_: self.menubar.show_system_dropdown(self.imac),
) )
@@ -63,7 +63,7 @@ class Panel(Window):
child=Svg( child=Svg(
size=16, size=16,
svg_file=get_relative_path( svg_file=get_relative_path(
"../../config/assets/icons/chevron-right.svg" "../../config/assets/icons/misc/chevron-right.svg"
), ),
), ),
on_clicked=self.toggle_tray, on_clicked=self.toggle_tray,
@@ -85,7 +85,7 @@ class Panel(Window):
on_clicked=lambda *_: self.search_apps(), on_clicked=lambda *_: self.search_apps(),
child=Svg( child=Svg(
size=20, size=20,
svg_file=get_relative_path("../../config/assets/icons/search.svg"), svg_file=get_relative_path("../../config/assets/icons/misc/search.svg"),
), ),
) )
@@ -100,7 +100,7 @@ class Panel(Window):
child=Svg( child=Svg(
size=22, size=22,
svg_file=get_relative_path( svg_file=get_relative_path(
"../../config/assets/icons/control-center.svg" "../../config/assets/icons/misc/control-center.svg"
), ),
), ),
) )
@@ -146,9 +146,9 @@ class Panel(Window):
if self.tray_revealer.child_revealed: if self.tray_revealer.child_revealed:
self.chevron_button.get_child().set_from_file( self.chevron_button.get_child().set_from_file(
get_relative_path("../../config/assets/icons/chevron-left.svg") get_relative_path("../../config/assets/icons/misc/chevron-left.svg")
) )
else: else:
self.chevron_button.get_child().set_from_file( self.chevron_button.get_child().set_from_file(
get_relative_path("../../config/assets/icons/chevron-right.svg") get_relative_path("../../config/assets/icons/misc/chevron-right.svg")
) )