Improved icns support

Adds support for PNG-encoded `.icns` files with of up to 512x512 (plus retina, so 1024x1024 at most).