added a widget for swaync and added keybinds for swaync
This commit is contained in:
@@ -46,4 +46,5 @@
|
|||||||
:halign 'end'
|
:halign 'end'
|
||||||
(hyprsunset)
|
(hyprsunset)
|
||||||
(datetime)
|
(datetime)
|
||||||
(stray)))
|
(stray)
|
||||||
|
(swaync)))
|
||||||
|
@@ -6,3 +6,4 @@
|
|||||||
@import 'widgets/hypr_activewindow.scss';
|
@import 'widgets/hypr_activewindow.scss';
|
||||||
@import 'widgets/hypr_workspaces.scss';
|
@import 'widgets/hypr_workspaces.scss';
|
||||||
@import 'widgets/sysmon.scss';
|
@import 'widgets/sysmon.scss';
|
||||||
|
@import 'widgets/swaync.scss';
|
||||||
|
@@ -6,3 +6,4 @@
|
|||||||
(include "widgets/hypr_workspaces.yuck")
|
(include "widgets/hypr_workspaces.yuck")
|
||||||
(include "widgets/hypr_activewindow.yuck")
|
(include "widgets/hypr_activewindow.yuck")
|
||||||
(include "widgets/sysmon.yuck")
|
(include "widgets/sysmon.yuck")
|
||||||
|
(include "widgets/swaync.yuck")
|
||||||
|
13
eww/widgets/swaync.scss
Normal file
13
eww/widgets/swaync.scss
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
.swaync{
|
||||||
|
background: aqua;
|
||||||
|
color: black;
|
||||||
|
&--dnd{
|
||||||
|
background: rosybrown;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
&--inhib{
|
||||||
|
background: indianred;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
19
eww/widgets/swaync.yuck
Normal file
19
eww/widgets/swaync.yuck
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
(deflisten notification :initial '{ "count": 0, "dnd": false, "visible": false, "inhibited": false }' "swaync-client -s")
|
||||||
|
|
||||||
|
(defvar swaync_icon_act "")
|
||||||
|
(defvar swaync_icon_inh "")
|
||||||
|
(defvar swaync_icon_dnd "")
|
||||||
|
|
||||||
|
(defwidget swaync []
|
||||||
|
(eventbox
|
||||||
|
:class "swaync${notification.dnd == true ? " swaync--dnd" : ""}${notification.inhibited == true ? " swaync--inhib" : ""}"
|
||||||
|
:cursor "pointer"
|
||||||
|
:onclick "swaync-client -t"
|
||||||
|
:onmiddleclick "swaync-client -d"
|
||||||
|
:onrightclick "swaync-client -C"
|
||||||
|
(box
|
||||||
|
:orientation "horizontal"
|
||||||
|
:spacing 3
|
||||||
|
:space-evenly false
|
||||||
|
(label :text "${notification.dnd == true ? swaync_icon_dnd : notification.inhibited == true ? swaync_icon_inh : swaync_icon_act}")
|
||||||
|
(label :text "${notification.count}"))))
|
@@ -6,14 +6,14 @@
|
|||||||
color: red
|
color: red
|
||||||
}
|
}
|
||||||
.ram{
|
.ram{
|
||||||
background: yellow;
|
background: tan;
|
||||||
}
|
}
|
||||||
.disk{
|
.disk{
|
||||||
background: lightblue;
|
background: mediumturquoise;
|
||||||
}
|
}
|
||||||
.cpu{
|
.cpu{
|
||||||
background: green;
|
background: lightgreen;
|
||||||
}
|
}
|
||||||
.net{
|
.net{
|
||||||
background: purple;
|
background: plum;
|
||||||
}
|
}
|
||||||
|
@@ -4,6 +4,8 @@ general {
|
|||||||
lock_cmd = pidof hyprlock || hyprlock # avoid starting multiple hyprlock instances.
|
lock_cmd = pidof hyprlock || hyprlock # avoid starting multiple hyprlock instances.
|
||||||
before_sleep_cmd = loginctl lock-session # lock before suspend.
|
before_sleep_cmd = loginctl lock-session # lock before suspend.
|
||||||
after_sleep_cmd = hyprctl dispatch dpms on # to avoid having to press a key twice to turn on the display.
|
after_sleep_cmd = hyprctl dispatch dpms on # to avoid having to press a key twice to turn on the display.
|
||||||
|
ignore_dbus_inhibit = false # whether to ignore dbus-sent idle-inhibit requests (used by e.g. firefox or steam)
|
||||||
|
ignore_systemd_inhibit = false # whether to ignore systemd-inhibit --what=idle inhibitors
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -33,5 +35,5 @@ listener {
|
|||||||
|
|
||||||
listener {
|
listener {
|
||||||
timeout = 3600 # 60min
|
timeout = 3600 # 60min
|
||||||
on-timeout = systemctl hybrid-sleep # hibernate and suspend pc
|
on-timeout = systemctl hibernate # hibernate and suspend pc
|
||||||
}
|
}
|
||||||
|
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
# Set programs that you use
|
# Set programs that you use
|
||||||
$terminal = uwsm app -T
|
$terminal = uwsm app -T
|
||||||
$filemanager = uwsm app -- dolphin
|
$filemanager = uwsm app -- nautilus
|
||||||
$launcher = uwsm app -- walker
|
$launcher = uwsm app -- walker
|
||||||
$clipboard = uwsm app -- nwg-clipman
|
$clipboard = uwsm app -- nwg-clipman
|
||||||
$browser = uwsm app -- zen-browser
|
$browser = uwsm app -- zen-browser
|
||||||
@@ -13,6 +13,11 @@ $editor = uwsm app -T -- vim
|
|||||||
$editor0 = uwsm app -- zeditor
|
$editor0 = uwsm app -- zeditor
|
||||||
$clipman = uwsm app -- nwg-clipman
|
$clipman = uwsm app -- nwg-clipman
|
||||||
$taskman = uwsm app -- uuctl walker -d
|
$taskman = uwsm app -- uuctl walker -d
|
||||||
|
$notcenter = uwsm app -- swaync-client -t -sw
|
||||||
|
$notdnd = uwsm app -- swaync-client -d
|
||||||
|
$nothide = uwsm app -- swaync-client --hide-latest
|
||||||
|
$notclose = uwsm app -- swaync-client --close-latest
|
||||||
|
$notcloseall = uwsm app -- swaync-client --close-all
|
||||||
|
|
||||||
$lockcmd = loginctl lock-session
|
$lockcmd = loginctl lock-session
|
||||||
|
|
||||||
@@ -32,8 +37,14 @@ bind = $mainMod, C, exec, $clipman
|
|||||||
bind = $mainMod, Return, exec, $terminal
|
bind = $mainMod, Return, exec, $terminal
|
||||||
bind = $mainMod, Escape, exec, $taskman
|
bind = $mainMod, Escape, exec, $taskman
|
||||||
|
|
||||||
bind = $mainMod SHIFT, C, exec, hyprctl reload # reload Hyprland
|
bind = $mainMod, Grave, exec, $notcenter
|
||||||
bind = $mainMod SHIFT, Pause, exit,
|
bind = $mainMod SHIFT, Grave, exec, $notdnd
|
||||||
|
bind = $mainMod, A, exec, $nothide
|
||||||
|
bind = $mainMod SHIFT, A, exec, $notclose
|
||||||
|
bind = $mainMod CTRL, A, exec, $notcloseall
|
||||||
|
|
||||||
|
|
||||||
|
bind = $mainMod SHIFT, Pause, exec, uwsm stop
|
||||||
bind = $mainMod, Pause, exec, $lockcmd
|
bind = $mainMod, Pause, exec, $lockcmd
|
||||||
bind = $mainMod SHIFT, Escape, exec, $lockcmd
|
bind = $mainMod SHIFT, Escape, exec, $lockcmd
|
||||||
|
|
||||||
|
2
uwsm/env
2
uwsm/env
@@ -3,7 +3,7 @@ export XCURSOR_THEME=phinger-cursors-light
|
|||||||
|
|
||||||
export GDK_BACKEND=wayland,x11,*
|
export GDK_BACKEND=wayland,x11,*
|
||||||
|
|
||||||
export SDL_VIDEODRIVER=wayland
|
export SDL_VIDEODRIVER=wayland,x11
|
||||||
export CLUTTER_BACKEND=wayland
|
export CLUTTER_BACKEND=wayland
|
||||||
|
|
||||||
export QT_QPA_PLATFORM=wayland;xcb
|
export QT_QPA_PLATFORM=wayland;xcb
|
||||||
|
Reference in New Issue
Block a user