I am trying to add a stretchable image as background in UIView with the following code. However, the image is shown one after another, but not stretched. Can anyone help me about it?
Code:
UIImage *theImage = [[UIImage imageNamed:@"BackgroundImage.png"] stretchableImageWithLeftCapWidth:0 topCapHeight:0];
[self setBackgroundColor:[UIColor colorWithPatternImage: theImage]];
Last edited by a moderator: