You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
## SwiftAutoLayout
2
2
3
-
SwiftAutoLayout is a tiny DSL for Autolayout (~90 LOC), intended to provide a more declarative way to express layout constraints. Here's a quick example:
3
+
SwiftAutoLayout is a tiny DSL for Autolayout intended to provide a more declarative way to express layout constraints. Here's a quick example:
4
4
5
5
```swift
6
6
// this:
@@ -23,6 +23,8 @@ SwiftAutoLayout allows you to more effectively communicate the intent of a const
23
23
24
24
Layout attributes are defined as properties added in extensions of `UIView` and `UILayoutGuide` on iOS and `NSView` and `NSLayoutGuide` on OS X. For example, `UIView.width` and `UIView.height` represent `NSLayoutAttribute.Width` and `NSLayoutAttribute.Height`, respectively.
25
25
26
+
Layout guides (conforming to `UILayoutSupport`) in `UIViewController` are also supported using the `topLayoutGuideTop`, `topLayoutGuideBottom`, `bottomLayoutGuideTop`, and `bottomLayoutGuideBottom` properties.
27
+
26
28
### Relations
27
29
28
30
Relations are expressed using the overloaded operators `==` (`NSLayoutRelation.Equal`), `>=` (`NSLayoutRelation.GreaterThanOrEqual`), and `<=` (`NSLayoutRelation.LessThanOrEqual`).
0 commit comments