diff options
| author | koem <koem@petoria.de> | 2013-02-13 01:07:35 +1300 |
|---|---|---|
| committer | koem <koem@petoria.de> | 2013-02-13 01:07:35 +1300 |
| commit | be8da094a918f63a977f9a0ee31e2cddee5af58d (patch) | |
| tree | 734620dd334735bfe23d8a3a9cea166b6631f440 /main/project/attributes/makeicons1res.sh | |
| parent | 6d450d980283b81e09fa774651c27ac77d229eb8 (diff) | |
| parent | 7b4a0b337a5f22bf0058c22967da94faea9ce318 (diff) | |
| download | cgeo-be8da094a918f63a977f9a0ee31e2cddee5af58d.zip cgeo-be8da094a918f63a977f9a0ee31e2cddee5af58d.tar.gz cgeo-be8da094a918f63a977f9a0ee31e2cddee5af58d.tar.bz2 | |
Merge branch 'master' into chooselist
Diffstat (limited to 'main/project/attributes/makeicons1res.sh')
| -rwxr-xr-x[-rw-r--r--] | main/project/attributes/makeicons1res.sh | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/main/project/attributes/makeicons1res.sh b/main/project/attributes/makeicons1res.sh index a6805ea..85e9fd7 100644..100755 --- a/main/project/attributes/makeicons1res.sh +++ b/main/project/attributes/makeicons1res.sh @@ -1,7 +1,6 @@ #!/bin/bash # # creates attribute icons in one resolution only -# target dir: ./drawable require () { hash $1 2>&- || { echo >&2 "I require $1 but it's not installed. Aborting."; exit 1; } @@ -12,6 +11,8 @@ require convert require composite require sed +# directory for icons +ICONDIR="./drawable-mdpi" # size of the image itself (inside border) IMGSIZE=32 # size of the whole icon @@ -31,14 +32,14 @@ SSTROKE=5 # color of the strikethru bar SCOL=\#c00000 # file name of strike thru bar -SFNAME="drawable/attribute__strikethru.png" +SFNAME="$ICONDIR/attribute__strikethru.png" #calculated values BNDIST=$(( ${ICONSIZE} - ${BDIST} )) res=48 # create output directory if missing -[ -d drawable ] || mkdir drawable +[ -d $ICONDIR ] || mkdir $ICONDIR # create border echo "drawing border" @@ -67,7 +68,7 @@ else svgs="svgs/*.svg" fi for s in $svgs; do - n=drawable/attribute_`basename "$s" | sed "s/\.svg//"` + n=$ICONDIR/attribute_`basename "$s" | sed "s/\.svg//"` # don't draw icons if svg is older than icon [ -f "${n}.png" ] && [ "$s" -ot "${n}.png" ] && continue |
