summary refs log tree commit diff stats
path: root/autorandr
diff options
context:
space:
mode:
Diffstat (limited to 'autorandr')
-rwxr-xr-xautorandr/.config/autorandr/postswitch10
1 files changed, 6 insertions, 4 deletions
diff --git a/autorandr/.config/autorandr/postswitch b/autorandr/.config/autorandr/postswitch
index c314da3..fc5d828 100755
--- a/autorandr/.config/autorandr/postswitch
+++ b/autorandr/.config/autorandr/postswitch
@@ -1,9 +1,11 @@
 #!/bin/sh
 DPI=96
-if [ "$1" != "laptop" ]
-then
-  DPI=144
-fi
+case $AUTORANDR_CURRENT_PROFILE in
+  ("laptop")
+    DPI=144;;
+  ("docked")
+    DPI=120;;
+esac
 
 xrandr --dpi $DPI
 emacsclient -e "(setq display-pixels-per-inch $DPI)" > /dev/null