ios - How to position a container view so it's the same distance from top of screen on iPhone 4 & iPhone 5? -
i have uiviewcontroller scrollview , containerview subview. have positioned containerview iphone 5 screen when load on iphone 4, of content should on screen cut off.
how ensure container view shows same amount of content bottom on both iphone 4 , iphone5 - i'm sorry if broad question if there's other information can provide let me know
thank you
if you're using layout constraints, give container view fixed constraint top , bottom of main view, , no fixed height. cause view expand , contract depending on screen size. depending scroll view is, 1 of constraints might have to it, rather top or bottom of screen (so, if scroll view on top, have constraint top, fixed height, , spacing constraint container view below it. container view need 1 bottom of superview).
Comments
Post a Comment