A Couple of iOS 7.1 UI Development Surprises (not the good kind)

Custom Track and Progress Images for UIProgressView broken

If you set trackImage and progressImage in UISliders, you’ll find these have broken in iOS 7.1.  They will be ignored and you will get the standard slider (at the standard 2 pixel height) instead.

Accessibility Bold Text affects images drawn with UIImageRenderingModeAlwaysTemplate

We are using ‘template’ images (UIImageRenderingModeAlwaysTemplate) for all of our buttons, so that iOS draws them using the shape of the image and a tint color.  However, in iOS 7.1, if the user turns on Bold Text under Accessibility, then all images drawn with the template rendering mode will have their pixels expanded to simulate a bold look.  For example, here is an image of a UIImageView and UIButton that use UIImageRenderingModeAlwaysTemplate with Bold Text turned off:

normalAnd here is the same app with Bold Text turned on:

bold

 

So, if you plan on using template images, be aware that they might be affected by accessibility settings.

 

Leave a Reply

Your email address will not be published. Required fields are marked *