From 412ae1b9338a54fbc5587feb65058378e79d8643 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Mon, 27 Apr 2026 21:14:13 +0300 Subject: [PATCH] docs: update README with new TOML-based config Signed-off-by: NotAShelf Change-Id: Iab7a0996b6733ae1b41c4a73fb2ab5256a6a6964 --- README.md | 36 ++++++++++++++++++++++-------------- 1 file changed, 22 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index e899265..9a6f5c0 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ comprehensive monitor management. Here's what makes Chroma stand out: - **Multiple image formats**: Supports JPEG, PNG, BMP, TGA, PSD, GIF, HDR, PIC, PPM, PGM - **EGL/OpenGL rendering**: Hardware-accelerated wallpaper rendering -- **Configuration file support**: Easy setup with INI-style config files +- **Simple Configuration file**: Easy setup with TOML config files - **Signal handling**: Graceful shutdown and configuration reload (SIGHUP) - **Intelligent downsampling**: Automatically reduces large image resolution to save memory (up to 94% memory savings for 8K images) @@ -96,27 +96,35 @@ make sample-config Chroma looks for configuration files in this order: -1. `~/.config/chroma/chroma.conf` -2. `$XDG_CONFIG_HOME/chroma/chroma.conf` -3. `./chroma.conf` (current directory) +1. `~/.config/chroma/chroma.toml` +2. `$XDG_CONFIG_HOME/chroma/chroma.toml` +3. `./chroma.toml` (current directory) #### Sample Configuration -```ini +```toml # Default wallpaper for outputs without specific mapping -default_image = ~/.config/chroma/default.jpg +default_image = "~/.config/chroma/default.jpg" # Output-specific wallpapers -# Format: output.OUTPUT_NAME = /path/to/image.jpg -output.DP-1 = ~/Pictures/monitor1.jpg -output.DP-2 = ~/Pictures/monitor2.png -output.HDMI-A-1 = ~/Pictures/hdmi_wallpaper.jpg +# Format: output.OUTPUT_NAME = "/path/to/image.jpg" +[output.DP-1] +image = "~/Pictures/monitor1.jpg" + +[output.DP-2] +image = "~/Pictures/monitor2.png" + +[output.HDMI-A-1] +image = "~/Pictures/hdmi_wallpaper.jpg" # You can also match outputs by description using the desc: prefix # This is useful when output names change between reboots -# Format: output.desc:DESCRIPTION_PREFIX = /path/to/image.jpg -output.desc:Samsung = ~/Pictures/samsung_wallpaper.jpg -output.desc:LG Ultra = ~/Pictures/lg_wallpaper.jpg +# Format: output."desc:DESCRIPTION_PREFIX" = "/path/to/image.jpg" +[output."desc:Samsung"] +image = "~/Pictures/samsung_wallpaper.jpg" + +[output."desc:LG Ultra"] +image = "~/Pictures/lg_wallpaper.jpg" ``` ### Finding Output Names @@ -140,7 +148,7 @@ Options: --version Show version information Examples: - chroma -c ~/.config/chroma/chroma.conf + chroma -c ~/.config/chroma/chroma.toml chroma --daemon ```