| Crates.io | dim-screen |
| lib.rs | dim-screen |
| version | 0.4.1 |
| created_at | 2024-02-24 01:21:56.714412+00 |
| updated_at | 2025-08-15 15:51:46.816842+00 |
| description | Native Wayland screen dimming tool |
| homepage | https://github.com/marcelohdez/dim |
| repository | |
| max_upload_size | |
| id | 1151165 |
| size | 97,141 |
Native Wayland screen dimming tool
[!NOTE] A Wayland compositor implementing the wlr-layer-shell-unstable-v1 protocol is required, e.g. Niri, Sway, Hyprland, River, Labwc.
After installing, you may run dim before you would run your locker, when
you want the screen to dim for a period, e.g. in your swayidle config/command:
timeout 270 'dim && swaylock'
Would make it so that at 270 seconds, dim is run waiting for user input
for the default of 30 seconds, then if no input is detected the next
command will proceed, in this case swaylock will lock your screen.
dim should only finish successfully when no input is detected for the
duration. If dim finishes successfully before this duration, please submit
an issue.
The alpha and duration of dim may be configured with either a config file
located at ~/.config/dim/config.toml, or through arguments at call-time, for
all options and their defaults please see:
dim --help
dim packages are titled as dim-screen to avoid naming conflicts.
dim is available in Fedora as a COPR:
sudo dnf copr enable marcelohdez/dim
sudo dnf install dim-screen
For Arch, dim is available in the AUR (Thanks to ge-garcia for maintaining!). You may use your preferred AUR helper like so:
paru -Syu dim-screen
[!IMPORTANT]
- Ensure you have Rust installed.
- The system libraries
libxkbcommonandlibwaylandare required.
dim is available on crates.io:
cargo install dim-screen
Choose a directory for this repo, then clone and cd into it:
git clone https://github.com/marcelohdez/dim
cd dim
Lastly, cargo can build and install dim for you, placing the binary in
$HOME/.cargo/bin/:
cargo install --path .
Or, if you would like to place the binary in your $PATH yourself:
cargo build -r
And the resulting binary should be in ./target/release/dim.
dim is licensed under the GPLv3 license, a free and open source license. For
more information, please refer to the LICENSE file in the repository root.