使用:padding-bottom 可兼容
原因:
从IOS8开始,属性var layoutMargins:UIEdgeInsets指定该View的subview同其edge的间距。AutoLayout使用margins来放置内容。其默认值为8pt。
如果一个View是ViewController的rootview,系统会自动设置和管理margins,top和bottom。margins为0pt。所以自己设定的margin-bottom会失效
使用:padding-bottom 可兼容
原因:
从IOS8开始,属性var layoutMargins:UIEdgeInsets指定该View的subview同其edge的间距。AutoLayout使用margins来放置内容。其默认值为8pt。
如果一个View是ViewController的rootview,系统会自动设置和管理margins,top和bottom。margins为0pt。所以自己设定的margin-bottom会失效