4 Please run src/tools/resources/optimize-png-files.sh on all new icons. For example:
5 tools/resources/optimize-png-files.sh -o2 new_pngs_dir
7 If this script does not work for some reason, at least pngcrush the files:
9 pngcrush -d crushed -brute -reduce -rem alla new/*.png
14 Windows ICO icons should be in the following format:
16 * A square image of each size: 256, 48, 32, 16.
17 * The 256 image should be in PNG format, and optimized.
18 * The smaller images should be in BMP (uncompressed) format.
19 * Each of the smaller images (48 and less) should have an 8-bit and 32-bit
21 * The 256 image should not be last (there is a bug in Gnome on Linux where icons
22 look corrupted if the PNG image is last).
24 If you are creating an ICO from a set of PNGs of different sizes, the following
25 process (using ImageMagick and GIMP) satisfies the above conditions:
27 1. Convert each of the smaller images to 8-bit. With ImageMagick:
29 for f in FILENAME-??.png; \
30 do convert $f -dither None -colors 256 \
31 png8:`basename $f .png`-indexed.png; \
34 2. Combine the images into an ICO file. With ImageMagick:
36 convert FILENAME-256.png FILENAME-{48,32,16}{-indexed,}.png FILENAME.ico
38 3. Unfortunately, the 8-bit images have been converted back into 32-bit images.
39 Open the icon in GIMP and re-export it. This will also convert the large
40 256 image into a compressed PNG.
41 4. Run src/tools/resources/optimize-ico-files.py on the resulting .ico file.
43 You can also run src/tools/resources/optimize-ico-files.py on existing .ico
44 files. This will run a basic PNG optimization pass.