wlr-dpms - 'xset dpms on|off' for wlroots compositors (git.sr.ht)
from dsemy@lemm.ee to linux@lemmy.ml on 28 Jan 2024 15:44
https://lemm.ee/post/22165175

I’ve been migrating my setup to Wayland the past few days, and I couldn’t figure out any way to turn off my displays without affecting the layout of the compositor (river).

As it turns out, there is a wlroots-specific protocol (wlr_output_power_manager_v1) for this purpose, but the only implementation I could find was a tool which doesn’t work exactly how I want and is based on Rust, a language I’m unfamiliar with (so I didn’t feel like modifying it).

Since I wanted to learn more about how Wayland works, and get more experience with C programming, I decided to build a new (super simple) tool, ‘wlr-dpms’.

Note that this tool only turns monitors on or off manually, it doesn’t implement any functionality to turn a monitor on when there is activity. You can use a resume command with ‘swayidle’ to implement this.

#linux

threaded - newest

lalo@discuss.tchncs.de on 28 Jan 2024 18:32 collapse

Looks similar to git.sr.ht/~leon_plickat/wlopm/

dsemy@lemm.ee on 28 Jan 2024 18:49 collapse

Damn, I searched for two days and didn’t come across this.

lalo@discuss.tchncs.de on 28 Jan 2024 18:55 collapse

You said you used river, so I’ve checked their wiki github.com/riverwm/river/…/Recommended-Software#o…

Maybe you can add your tool there as well.

dsemy@lemm.ee on 28 Jan 2024 19:00 collapse

Wow, I have no idea how I missed that, I literally read that page today.