测试已测试 | ✗ |
语言语言 | SwiftSwift |
许可证 | MIT |
发布最新发布 | 2017年11月 |
SwiftSwift 版本 | 3.0 |
SPM支持 SPM | ✗ |
由 Jose Quintero 维护。
QLayout 是一款使 iOS 上的 Auto Layout 变得容易的实用工具。
要使用 CocoaPods 将 QLayout 集成到您的 Xcode 项目中,在 Podfile 中指定它
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!
target '<Your Target Name>' do
pod 'QLayout'
end
然后,运行以下命令
$ pod install
import QLayout
class ViewController: UIViewController {
lazy var subView = UIView()
override func viewDidLoad() {
super.viewDidLoad()
self.view.addSubview(subView)
subView.layout.width.height.equalTo(50)
subView.layout.center.equalTo(view)
}
}
QLayout 采用 MIT 许可证发布。有关详细信息,请参阅 LICENSE 文件。