title: How to invert UIImage preserving alpha?
body: <p>On my <code>UITableViewCell</code> I set <code>imageView.image</code>.  This is a simple black icon on a transparent background.</p>
  
  <p>I want to invert it, when the cell is selected/highlighted, which can be done by setting the cell's <code>imageView.highlightedImage</code>.</p>
  
  <p>I've tried <a href="https://stackoverflow.com/a/17006328/1971013">this</a> but that returns nil, and also tried <a href="https://stackoverflow.com/a/9944299/1971013">this</a> which turns transparent parts white so you see a white square when cell is selected.</p>
  
  <p>What's the proper way to invert a <code>UIImage</code> for this purpose (which works for both normal and retina screens)?  So, I only want to invert the colours; alpha should be preserved.</p>