Instance Method

imageForState:

Returns the image used for a button state.

Declaration

- (UIImage *)imageForState:(UIControlState)state;

Parameters

state

The state that uses the image. Possible values are described in UIControlState.

Return Value

The image used for the specified state.

See Also

Configuring Button Presentation

adjustsImageWhenHighlighted

A Boolean value that determines whether the image changes when the button is highlighted.

adjustsImageWhenDisabled

A Boolean value that determines whether the image changes when the button is disabled.

showsTouchWhenHighlighted

A Boolean value that determines whether tapping the button causes it to glow.

- backgroundImageForState:

Returns the background image used for a button state.

- setBackgroundImage:forState:

Sets the background image to use for the specified button state.

- setImage:forState:

Sets the image to use for the specified state.

tintColor

The tint color to apply to the button title and image.