From bfca1a127b88eb27685df783033ef17248396792 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20T=C5=AFma?= Date: Sat, 29 May 2021 00:22:24 +0200 Subject: [PATCH] Use rsvg instead of imagemagick for SVG->PNG conversion on OS X --- icons/formats/scripts/icns.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/icons/formats/scripts/icns.sh b/icons/formats/scripts/icns.sh index 7d9772bb..f71eadb2 100755 --- a/icons/formats/scripts/icns.sh +++ b/icons/formats/scripts/icns.sh @@ -9,16 +9,16 @@ while read e; do ICONSET=$1.iconset mkdir $ICONSET - convert -density 400 -background none -resize '16x16' "$1.svg" "$ICONSET/icon_16x16.png" - convert -density 400 -background none -resize '32x32' "$1.svg" "$ICONSET/icon_16x16@2x.png" + rsvg-convert -w 16 -h 16 -o "$ICONSET/icon_16x16.png" "$1.svg" + rsvg-convert -w 32 -h 32 -o "$ICONSET/icon_16x16@2x.png" "$1.svg" cp "$ICONSET/icon_16x16@2x.png" "$ICONSET/icon_32x32.png" - convert -density 400 -background none -resize '64x64' "$1.svg" "$ICONSET/icon_32x32@2x.png" - convert -density 400 -background none -resize '128x128' "$1.svg" "$ICONSET/icon_128x128.png" - convert -density 400 -background none -resize '256x256' "$1.svg" "$ICONSET/icon_128x128@2x.png" + rsvg-convert -w 64 -h 64 -o "$ICONSET/icon_32x32@2x.png" "$1.svg" + rsvg-convert -w 128 -h 128 -o "$ICONSET/icon_128x128.png" "$1.svg" + rsvg-convert -w 256 -h 256 -o "$ICONSET/icon_128x128@2x.png" "$1.svg" cp "$ICONSET/icon_128x128@2x.png" "$ICONSET/icon_256x256.png" - convert -density 400 -background none -resize '512x512' "$1.svg" "$ICONSET/icon_256x256@2x.png" + rsvg-convert -w 512 -h 512 -o "$ICONSET/icon_256x256@2x.png" "$1.svg" cp "$ICONSET/icon_256x256@2x.png" "$ICONSET/icon_512x512.png" - convert -density 400 -background none -resize '1024x1024' "$1.svg" "$ICONSET/icon_512x512@2x.png" + rsvg-convert -w 1024 -h 1024 -o "$ICONSET/icon_512x512@2x.png" "$1.svg" iconutil -c icns -o $1.icns "$ICONSET" rm -R "$ICONSET" $1.svg