reworked PR from @matthusby

after looking at the UIColor+Helpers class mentioned by @koke, Fixes #1920