Copy Papirus mimetypes at all sizes for crisp file icons
Previously only copied 64x64, causing blurry icons when scaled. Now copies 16x16 through 128x128 so icons render at native resolution at any zoom level. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
043dd3674c
commit
54cda24cda
1 changed files with 43 additions and 7 deletions
|
|
@ -7,7 +7,7 @@ PAPIRUS="/run/current-system/sw/share/icons/Papirus-Dark"
|
||||||
|
|
||||||
mkdir -p "$ICON_DIR/scalable/places"
|
mkdir -p "$ICON_DIR/scalable/places"
|
||||||
|
|
||||||
# Create index.theme
|
# Create index.theme with all mimetype sizes
|
||||||
cat > "$ICON_DIR/index.theme" << 'THEME'
|
cat > "$ICON_DIR/index.theme" << 'THEME'
|
||||||
[Icon Theme]
|
[Icon Theme]
|
||||||
Name=WallpaperAdwaita
|
Name=WallpaperAdwaita
|
||||||
|
|
@ -22,9 +22,43 @@ MaxSize=512
|
||||||
Type=Scalable
|
Type=Scalable
|
||||||
Context=Places
|
Context=Places
|
||||||
|
|
||||||
|
[16x16/mimetypes]
|
||||||
|
Size=16
|
||||||
|
Type=Fixed
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
|
[22x22/mimetypes]
|
||||||
|
Size=22
|
||||||
|
Type=Fixed
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
|
[32x32/mimetypes]
|
||||||
|
Size=32
|
||||||
|
Type=Fixed
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
|
[48x48/mimetypes]
|
||||||
|
Size=48
|
||||||
|
Type=Fixed
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
[64x64/mimetypes]
|
[64x64/mimetypes]
|
||||||
Size=64
|
Size=64
|
||||||
MinSize=16
|
MinSize=32
|
||||||
|
MaxSize=128
|
||||||
|
Type=Scalable
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
|
[96x96/mimetypes]
|
||||||
|
Size=96
|
||||||
|
MinSize=64
|
||||||
|
MaxSize=256
|
||||||
|
Type=Scalable
|
||||||
|
Context=MimeTypes
|
||||||
|
|
||||||
|
[128x128/mimetypes]
|
||||||
|
Size=128
|
||||||
|
MinSize=64
|
||||||
MaxSize=512
|
MaxSize=512
|
||||||
Type=Scalable
|
Type=Scalable
|
||||||
Context=MimeTypes
|
Context=MimeTypes
|
||||||
|
|
@ -42,11 +76,13 @@ for svg in "$ADWAITA/scalable/places"/*.svg; do
|
||||||
"$svg" > "$ICON_DIR/scalable/places/$name"
|
"$svg" > "$ICON_DIR/scalable/places/$name"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Copy Papirus mimetype icons for better file type distinction
|
# Copy Papirus mimetype icons at all available sizes
|
||||||
if [ -d "$PAPIRUS/64x64/mimetypes" ]; then
|
for size in 16x16 22x22 32x32 48x48 64x64 96x96 128x128; do
|
||||||
mkdir -p "$ICON_DIR/64x64/mimetypes"
|
if [ -d "$PAPIRUS/$size/mimetypes" ]; then
|
||||||
cp -a "$PAPIRUS/64x64/mimetypes"/* "$ICON_DIR/64x64/mimetypes/"
|
mkdir -p "$ICON_DIR/$size/mimetypes"
|
||||||
fi
|
cp -a "$PAPIRUS/$size/mimetypes"/* "$ICON_DIR/$size/mimetypes/"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
# Update icon cache
|
# Update icon cache
|
||||||
gtk-update-icon-cache -f "$ICON_DIR" 2>/dev/null || true
|
gtk-update-icon-cache -f "$ICON_DIR" 2>/dev/null || true
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue