From 1ca280b6016f8f762411a44f53c44981bb9246c5 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 22 Jul 2024 16:53:31 +0200 Subject: .. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- xorg-xrandr/resolution-changed | 14 +++++++++++--- xorg-xrandr/setres/__main__.py.gpp | 10 ++++++++++ 2 files changed, 21 insertions(+), 3 deletions(-) (limited to 'xorg-xrandr') diff --git a/xorg-xrandr/resolution-changed b/xorg-xrandr/resolution-changed index e1457ce..4e8856f 100755 --- a/xorg-xrandr/resolution-changed +++ b/xorg-xrandr/resolution-changed @@ -1,15 +1,23 @@ #!/bin/dash reset_wallpaper_twice=0 +hostname="$(hostname | tr 'A-Z' 'a-z')" -if ! test "$(hostname | tr '[A-Z]' '[a-z]')" = zenith; then +if ! test "${hostname}" = zenith; then ## TODO how about the other east,north,hades,hyperion? # Reset rat size in case DPI change modified scaling xsetroot -cursor_name left_ptr || : # Reset rat speed in case DPI changed if test "${DESKTOP_SESSION}" = xmonad && test ! "${NO_MATE}" = y; then - msd=/usr/lib/mate-settings-daemon/mate-settings-daemon - if ! test -x "$msd"; then + if test -x /usr/lib/mate-settings-daemon/mate-settings-daemon; then + msd=/usr/lib/mate-settings-daemon/mate-settings-daemon + elif test -x /usr/bin/mate-settings-daemon; then + msd=/usr/bin/mate-settings-daemon + elif test -x /usr/libexec/mate-settings-daemon; then + msd=/usr/libexec/mate-settings-daemon + elif test -x /usr/libexec/mate-settings-daemon/mate-settings-daemon; then + msd=/usr/libexec/mate-settings-daemon/mate-settings-daemon + else msd=mate-settings-daemon fi (exec $msd --replace &) || : diff --git a/xorg-xrandr/setres/__main__.py.gpp b/xorg-xrandr/setres/__main__.py.gpp index 3a79328..b25f9d6 100755 --- a/xorg-xrandr/setres/__main__.py.gpp +++ b/xorg-xrandr/setres/__main__.py.gpp @@ -60,6 +60,16 @@ elif hostname == 'hades': embed.want_mode = '1920x1280' +elif hostname == 'north': + prime = None + sec = None + embed = screen['eDP1'] + + prime_alt = None + sec_alt = None + + embed.want_mode = '1920x1080' + %%>hostname="$(hostname | tr '[A-Z]' '[a-z]')" %%>file="${HOME}/.dotfiles/.private/setres/${hostname}" %%>if test -r "${file}"; then -- cgit v1.2.3-70-g09d2