KDE Wayland Power Button Screen Toggle
Power button as a screen on/off toggle on KDE Plasma (Wayland): mouse and keyboard can't wake the screens, the button can't shut down
About This Project
{ "summary": "A Python utility that repurposes the physical power button on KDE Plasma Wayland systems as a dedicated screen on/off toggle.", "description": "This project provides a reliable method to toggle monitor power states on KDE Plasma Wayland environments by preventing standard input devices from waking the screens. By utilizing the python3-evdev library to take exclusive control of the power button and input devices, it bypasses the limitations of traditional DPMS methods where mouse or keyboard movement inadvertently wakes the display. The script runs as a systemd user service, ensuring that the power button is reserved for screen control while simultaneously disabling system shutdown or suspend triggers.\n\nThe utility is designed for users who require a persistent desktop environment where displays must remain off until manually toggled. It includes support for remote control via systemd signals, allowing for integration with automation tools like Home Assistant. The implementation ensures system safety by automatically releasing input device locks if the service stops or crashes, preventing users from being locked out of their sessions.", }