ViewLayout
安装
只需将以下行添加到您的 Podfile
pod 'ViewLayout'
屏幕截图
用法与示例
示例:直接在使用的文件中导入 Masonry 的 UI 样式
#import "UIView+layout.h"
[self.view addSubview:self.tableView];
[self.tableView layout_fill];
LLExampleBasicView 文件
[greenView layout_top:padding relation:NSLayoutRelationGreaterThanOrEqual toView:superview toAttribute:NSLayoutAttributeTop];
[greenView layout_left:padding toView:superview];
[greenView layout_bottom:-padding toView:blueView toAttribute:NSLayoutAttributeTop];
[greenView layout_right:-padding toView:redView toAttribute:NSLayoutAttributeLeft];
[greenView layout_widthEqualToView:redView];
[greenView layout_heightEqualToView:redView];
[greenView layout_heightEqualToView:blueView];
许可协议
ViewLayout 在 MIT 开源许可下提供。有关更多信息,请参阅_LICENSE 文件。