简体   繁体   中英

How to make the view of a UIViewController to stick to the bottom of it's superview?

Programmatically, and not with using xib files? UIView's autoresizingMask is not really the right thing, I think. Since it's not about resizing but laying out. I couldn't find layout masks. But Interface Builder seems to allow to attach a view to top, left, right, center or bottom. So there must be a mechanism.

https://developer.apple.com/documentation/uikit/uiview/1622559-autoresizingmask

[view setAutoresizingMask: UIViewAutoresizingFlexibleTopMargin];

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM