A. Picture stretching problem:
Create a UIImage object from a picture name (the way the picture is created, is stretched very ugly)
UIImage *image = [UIImage imagenamed:@ "Chat_send_nor"];
Call a method from the image object to return a stretched picture
Pass in the area you want to protect
Uiedgeinsets insets = uiedgeinsetsmake (image.size.height * 0.5, Image.size.width * 0.5, Image.size.height * 0.5-1, image . Size.width * 0.5-1);
UIImage *resizableimage = [Image resizableimagewithcapinsets:insets];
Uiimageresizingmodetile, tiling, tiling where you need to stretch with unprotected areas
Uiimageresizingmodestretch, stretching, stretching directly to unprotected areas
UIImage *resizabeleimage = [Image resizableimagewithcapinsets:insets Resizingmode:uiimageresizingmodestretch];
Two. Three ways to modify frame
Picture of the stretching problem, the way to modify the frame,