Skip to content

enzohideo/azalea-desktop-shell

Repository files navigation

Azalea is a compositor agnostic desktop shell for Wayland written in Rust.

Compatibility

It runs on any compositor that implements wlroots' Layer Shell protocol.

  • Hyprland
  • Sway
  • KWin
  • Niri
  • Wayfire
  • Others

Crates

  • azalea: main application
  • azalea-core: Core library (cli, config parser, sockets, window management, etc)
  • azalea-log: Wrappers around glib's log functions
  • azalea-service: Service traits
  • azalea-derive: Derive macros
  • azalea-shell: Implementation of services and widgets

Nix

This project uses nix to package and test Azalea on different wayland compositors.

Development shell

nix shell
cargo run daemon start

Build and run

nix run

NixOS VM Tests

Testing azalea on different wayland compositors

# Automatized tests, screenshots are saved to ./result
nix build .#test

# Interactive tests
nix run .#test.driverInteractive

Note

This uses a lot of resources to spin up the VM

Without nix

It's possible to build the project without nix, but you'd need to install all the dependencies yourself.

src = craneLib.cleanCargoSource ../.;
commonArgs = {
inherit src;
strictDeps = true;
nativeBuildInputs = [
rustPlatform.bindgenHook
pkg-config
wrapGAppsHook4
clang
mold-wrapped
];
buildInputs = [
gtk4
gtk4-layer-shell
openssl
dbus
alsa-lib
];
NIX_OUTPATH_USED_AS_RANDOM_SEED = "aaaaaaaaaa";
};

Useful resources

This project uses gtk4 (relm4) and gtk4-layer-shell, but there are a few other libraries that could have been used:

  • qt + layer-shell-qt (poor Rust support, but it works great on C++)
  • iced + iced-layershell (pure Rust library, but relatively poor performance)

Here are a few useful resources for learning gtk4 and relm4.

There are also high level libraries made specifically for building desktop shell components:

Other interesting Wayland protocols

Here are some interesting protocols that are worth exploring:

About

Azalea is a Desktop Shell that works in any Wayland compositor that implements Layer Shell

Resources

License

Stars

Watchers

Forks

Contributors