stylix: pull Papirus folder variants into the recoloured icon theme

Adwaita's scalable/places ships only the generic folder.svg, so
Downloads, Pictures, Music etc. all rendered as the same icon. Copy
Papirus' places at every size into WallpaperAdwaita and recolour the
Papirus blues to the stylix primary. Declare the sized places
directories in index.theme so GTK actually looks at them.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
ediblerope 2026-05-12 09:44:42 +01:00
parent a3e91d4fe6
commit 5e479cc394

View file

@ -104,6 +104,47 @@
Type=Scalable
Context=Places
[16x16/places]
Size=16
Type=Fixed
Context=Places
[22x22/places]
Size=22
Type=Fixed
Context=Places
[32x32/places]
Size=32
Type=Fixed
Context=Places
[48x48/places]
Size=48
Type=Fixed
Context=Places
[64x64/places]
Size=64
MinSize=32
MaxSize=128
Type=Scalable
Context=Places
[96x96/places]
Size=96
MinSize=64
MaxSize=256
Type=Scalable
Context=Places
[128x128/places]
Size=128
MinSize=64
MaxSize=512
Type=Scalable
Context=Places
[16x16/mimetypes]
Size=16
Type=Fixed
@ -159,6 +200,26 @@
done
fi
# Papirus has proper distinct folder icons for Downloads, Pictures,
# Music, etc — copy and recolour them with the wallpaper accent so
# we don't end up with a single generic folder everywhere.
for size in 16x16 22x22 32x32 48x48 64x64 96x96 128x128; do
if [ -d "$PAPIRUS/$size/places" ]; then
$DRY_RUN_CMD rm -rf "$ICON_DIR/$size/places"
$DRY_RUN_CMD mkdir -p "$ICON_DIR/$size/places"
for svg in "$PAPIRUS/$size/places"/*.svg; do
[ -f "$svg" ] || continue
name=$(basename "$svg")
$DRY_RUN_CMD sed \
-e "s/#5294e2/$PRIMARY/gi" \
-e "s/#4877b1/$PRIMARY/gi" \
-e "s/#729fcf/$PRIMARY/gi" \
-e "s/#689ad6/$PRIMARY/gi" \
"$svg" > "$ICON_DIR/$size/places/$name"
done
fi
done
for size in 16x16 22x22 32x32 48x48 64x64 96x96 128x128; do
if [ -d "$PAPIRUS/$size/mimetypes" ]; then
$DRY_RUN_CMD rm -rf "$ICON_DIR/$size/mimetypes"