[arandr-users] Rerandr3 and better save/restore mechanism for Arandr
Vladimir Kudrya
vladimir-csp at yandex.ru
Thu Mar 3 05:53:33 UTC 2016
Hello everyone!
Some months ago I mailed chrysn about improving save/restore mechanisms
in Arandr and my xrandr wrapper/daemon script called rerandr3.
Unfortunately, I didn't get any response.
Anyway, some of you might be interested in this script and ideas behind it.
The project is hosted here: https://github.com/Vladimir-csp/rerandr3
Rerandr3 features:
- On-demand save of current outputs configuration in relation to
combination of outputs and display device models. (complete with
geometry, properties, primary screen).
- Restore outputs configuration for familiar combinations.
- Auto-enable and stack outputs on new unfamiliar combinations.
- Running as a daemon it can restore or auto-stack outputs on hot-plug
in fully automatic mode, triggered by udev rule.
- Runs different sets of hooks depending on virtual screen size.
- Works around poor xrandr CRTCs handling.
- Temporarily preserves framebuffer size while switching outputs to
prevent windows positioning mess
- Tries to avoid unnecessary switching, aplying only delta operations.
Throughout the past half a year I've squashed some bugs and it served me
reliably and unobtrusively while moving between home and work and
plugging in some new displays.
What it has to do with Arandr? It could provide a backend for smart
save/restore and hotplug actions handling which Arandr is lacking. Or it
could serve as a model for implementing such features in Arandr itself.
As a test, I once dirty-hacked (I'm not so comfy outside bash) Arandr
purging everything except layout editor and "Apply" button, and adding
trigger to run "rerandr3 hooks" and "rerandr3 save" on "Apply". Proved
to be a very practical combination on the outside.
Cheers!
More information about the arandr-users
mailing list