Skip to content

Sv1nnet/GUI-for-dimland

 
 

Repository files navigation

Dimland GUI

This is a GUI for dimland built with Tauri and Preact. Moved all files from my initial project.

Known issues

Tauri has an issue with a glitchy window when the application is launched. You can fix this by manually resizing the window after opening it. I tried the suggestions mentioned in the issue conversation, but none of them worked. If you have any ideas on how to fix it, you are welcome to submit a PR.

If you have issues installing dimland itself, you can check the original repository: https://github.com/keifufu/dimland

Below you can find the original dimland instructions:

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 with gui

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Rust 42.2%
  • JavaScript 29.4%
  • CSS 14.9%
  • Shell 10.4%
  • Nix 2.7%
  • HTML 0.4%