Add Super + Ctrl + Backspace to toggle resolution between 1-2-3x
This commit is contained in:
Executable
+21
@@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Get the current scale from the first monitor
|
||||||
|
CURRENT_SCALE=$(hyprctl monitors -j | jq -r '.[0].scale')
|
||||||
|
|
||||||
|
# Define the scaling cycle based on current scale
|
||||||
|
# Cycles through 1.00 → 2.00 → 3.13 → 1.00
|
||||||
|
case "$CURRENT_SCALE" in
|
||||||
|
1.00) NEW_SCALE="2" ;;
|
||||||
|
2.00) NEW_SCALE="3.13" ;;
|
||||||
|
3.13) NEW_SCALE="1" ;;
|
||||||
|
*) NEW_SCALE="2" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# Apply the new scale to all monitors
|
||||||
|
hyprctl monitors -j | jq -r '.[].name' | while read -r monitor; do
|
||||||
|
hyprctl keyword monitor "$monitor,preferred,auto,$NEW_SCALE"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Notify the user
|
||||||
|
notify-send " Display scaling set to ${NEW_SCALE}x"
|
||||||
@@ -28,6 +28,9 @@ bindd = SUPER CTRL, I, Toggle locking on idle, exec, omarchy-toggle-idle
|
|||||||
# Toggle nightlight
|
# Toggle nightlight
|
||||||
bindd = SUPER CTRL, N, Toggle nightlight, exec, omarchy-toggle-nightlight
|
bindd = SUPER CTRL, N, Toggle nightlight, exec, omarchy-toggle-nightlight
|
||||||
|
|
||||||
|
# Toggle monitor scaling
|
||||||
|
bindd = SUPER CTRL, Backspace, Toggle monitor scaling, exec, omarchy-toggle-monitor-scaling
|
||||||
|
|
||||||
# Control Apple Display brightness
|
# Control Apple Display brightness
|
||||||
bindd = CTRL, F1, Apple Display brightness down, exec, omarchy-brightness-display-apple -5000
|
bindd = CTRL, F1, Apple Display brightness down, exec, omarchy-brightness-display-apple -5000
|
||||||
bindd = CTRL, F2, Apple Display brightness up, exec, omarchy-brightness-display-apple +5000
|
bindd = CTRL, F2, Apple Display brightness up, exec, omarchy-brightness-display-apple +5000
|
||||||
|
|||||||
Reference in New Issue
Block a user