ios - Scale up UIImageView (Storyboard Autoresizing) -
i have uiimageview in storyboard. image used square. imageview width , height equivalent. want take advantage of autoresizing in storyboard, on small device image scaled down , on large device image scaled up. when test on iphone 5 scaling appropriate. however, when running on ipad results different. square stretched, , makes sense dimensions of screen different dimensions of iphone. how can avoid issue, there process in can scale view whole until height same height of ipad , centre view?
note - image has same width , height , content mode set 'aspect fit'
follow procedure
1) add view in content added going use 2 views newview[with content] , baseview
now time add constraints newview leading, trailing,bottom , top [adding wr hr component]
result ipad
result iphone
Comments
Post a Comment