Can I change the alpha of just the button's background image? If I change the button's alpha [button setAlpha: 0.2] the text's alpha changes as well and I'd like the text to stay bright white. Any way?
Don't think so directly. You could create a new blank image and draw the existing image into with a given alpha value, then set that as the button's image.
Don't think so directly. You could create a new blank image and draw the existing image into with a given alpha value, then set that as the button's image.
But when I click a button it looks like the background alpha changes while the text changes color over top.
adjustsImageWhenHighlighted
A Boolean value that determines whether the image changes when the button is highlighted.
@property(nonatomic) BOOL adjustsImageWhenHighlighted
Discussion
If YES, the image is drawn lighter when the button is highlighted. The default value is YES.