Skip to content

keifufu/dimland

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dimland

Dimland is a simple screen dimmer for Wayland. It overlays a transparent black layer on all display outputs, enabling additional brightness reduction, even when the monitor backlight is to 0%. It also includes a feature for drawing opaque screen corners, mimicking a rounded display.

Installation

Nix

The preferred way to install dimland is using the Nix package manager.

nix profile install github:keifufu/dimland
NixOS

This assumes you use home manager with flakes.

  • Add github:keifufu/dimland to your inputs
  • Import inputs.dimland.homeManagerModules.dimland
  programs.dimland = {
    enable = true;
    # If you want to start dimland on startup
    service = {
      enable = true;
      alpha = 0;
      radius = 20;
      # Specify target to start after
      after = "hyprland-started.path";
    };
  };

  # Assuming you use Hyprland, start after its socket exists
  systemd.user.paths.hyprland-started = {
    Unit.Description = "Watch for Hyprland to start";
    Path.PathExists = "%t/hypr";
    Install.WantedBy = [ "default.target" ];
  };

Building Manually

Important

  • Ensure you have Rust installed.
  • The system libraries libxkbcommon and libwayland are required.
cargo build --release

The resulting binary will be in ./target/release/dimland

Usage

Usage: dimland [OPTIONS] [COMMAND]

Commands:
  stop  Stops the program
  help  Print this message or the help of the given subcommand(s)

Options:
  -a, --alpha <ALPHA>    Transparency level (0.0 transparent, 1.0 opaque, default 0.5, max 0.9)
      --allow-opaque     Allow alpha to go beyond 0.9
  -r, --radius <RADIUS>  Corner radius (default 0)
  -o, --output <OUTPUT>  Output to control (ex. DP-1)
  -h, --help             Print help
  -V, --version          Print version

About

wayland screen dimmer

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published