scheme: better colour generation

Pass okolors colours through material and use primary (except for mono scheme)
Mono is the same
This commit is contained in:
2 * r + 2 * t
2025-03-28 23:04:44 +11:00
parent e9cf7459a0
commit 9a9fdb39a4
2 changed files with 48 additions and 16 deletions
+2 -7
View File
@@ -7,19 +7,14 @@ set -l src (dirname (status filename))
test -f "$argv[1]" && set -l img (realpath "$argv[1]") || set -l img $C_STATE/wallpaper/thumbnail.jpg
contains -- "$argv[2]" light dark && set -l theme $argv[2] || set -l theme dark
set -l variants vibrant tonalspot expressive fidelity fruitsalad rainbow neutral content
set -l variants vibrant tonalspot expressive fidelity fruitsalad rainbow neutral content monochrome
# Generate colours
test $theme = light && set -l lightness 50 || set -l lightness 70
set -l colours (okolors $img -k 14 -w 0 -l $lightness)
set -l colours (okolors $img -k 14)
for variant in $variants
mkdir -p $src/../data/schemes/dynamic/$variant
$src/autoadjust.py $theme $variant $colours > $src/../data/schemes/dynamic/$variant/$theme.txt
end
mkdir -p $src/../data/schemes/dynamic/monochrome
$src/autoadjust.py $theme monochrome (okolors $img -k 14) > $src/../data/schemes/dynamic/monochrome/$theme.txt
set -la variants monochrome
# Generate layers and accents
set -l tmp (mktemp)