Bunyod
Bunyod

Reputation: 1371

How can i duplicate image in iOS?

I've UIImageVeiw. It's height must change dynamically by scrollview content size height. When I resize, it is changing the image quality. How can i duplicate image until it matches scrollview height? Please help me. Thanks in advance.

Upvotes: 0

Views: 150

Answers (1)

Petar
Petar

Reputation: 2283

To achieve that you must use a pattern image:

UIColor *patternColor = [UIColor colorWithPatternImage:@"<your pattern image name>"];
<your view>.backgroundColor = patternColor;

Upvotes: 1

Related Questions