Instance Method

imageWithTintColor:

Returns a new version of the current image with the specified tint color applied.

Declaration

- (UIImage *)imageWithTintColor:(UIColor *)color;

Parameters

color

The tint color to apply to the image.

Return Value

A new version of the image that incorporates the specified tint color.

Discussion

For bitmap images, this method draws the background tint color followed by the image contents using the kCGBlendModeDestinationIn mode. For symbol images, this method returns an image that always uses the specified tint color.

The new image uses the same rendering mode as the original image.

See Also

Tinting the Image

- imageWithTintColor:renderingMode:

Returns a new version of the image with a tint color applied using the specified rendering mode.