diff --git a/bin/omarchy-toggle-monitor-scaling b/bin/omarchy-toggle-monitor-scaling new file mode 100755 index 00000000..a6cc7bc4 --- /dev/null +++ b/bin/omarchy-toggle-monitor-scaling @@ -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" diff --git a/default/hypr/bindings/utilities.conf b/default/hypr/bindings/utilities.conf index 3c3629fe..ae801ada 100644 --- a/default/hypr/bindings/utilities.conf +++ b/default/hypr/bindings/utilities.conf @@ -28,6 +28,9 @@ bindd = SUPER CTRL, I, Toggle locking on idle, exec, omarchy-toggle-idle # 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 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