Detect when a output interface has been disconnected #862
Unanswered
bphenriques
asked this question in
Q&A
Replies: 1 comment 5 replies
-
Hey! While niri doesn't expose output events in its own IPC (yet?), it does expose them via wlr-output-management. It's used by tools like kanshi. I see the tools you linked also use it. |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I successfuly setup a working solution that allows me to setup my outputs configuration (internal/external/extended). However, I often unplug the HDMI cable of my laptop while it is in docked mode, and as far as I can tell there is no way in
niri
directly to detect when that happens so that I can revert back to the internal display. Currently, when I unplug the cable, no output is displayed and there is nothing I can do without rebooting the laptop.This is what happens when I unplugin the cable:
All
output
are set tonull
which indicated that nooutput
is available atm. I can work around so that I can listen to the event and enableeDP-1
again. However, it is a side-channel and not a dedicated channel to get the event I am looking for.This led me to:
outputs
are connected/disconnected (at minimum)? I can run that on the background.niri
to keep at least oneoutput
enabled if the current ones are disconnected. I noticed that niri does not safeguard against that when setting one tooff
which I think is reasonable by design.keishin
or similar tools (shikane
). I ask this as I am unsure if my configuration should be mirrored on bothniri
or keishin/shikane configuration. I triedkeishin
but I found it unreliable but I don't have concrete proof. I will try shikane in the mean-time. It is likely out-of-scope for niri but feels worthwhile asking given that it is very common use-case.Relates but not the same thing as:
Beta Was this translation helpful? Give feedback.
All reactions