Learn how to use constraints with inequalities to size constraints.
- [Instructor] I've messed up the app…by letting everything go to its intrinsic content size.…Besides sides constraints,…you can control it using inequalities and priorities.…Inequalities give a range of values auto layout can use…to size the view.…Go ahead and stop the app and go back to the code.…Head down to layout views to start.…We'll put back some of our constraints…and we'll head over to add button view.…
Here I'm going to put back the order button dot width.…I'm gonna copy the back button dot height.…Paste it underneath.…Open up the constraint.…This time I'm gonna change it into an order button.…I have an order button and a back button height.…Now we've left related by as equal for this course.…
It's time to start playing around with that…and hit the dot or period,…and you'll see there are three options here.…Equal, great than or equal, or less than equal.…You can make things less than or equal to your attribute…or greater than or equal to your attribute.…I'm gonna go for less than or equal.…I need to mention that up here.…
- When and why to use Auto Layout programmatically
- Creating constraints in Swift
- Resolving errors in Auto Layout
- Using the safe area
- Working with the Visual Format Language
- Adding a stack view
- Harnessing the power of inequalities and priorities in constraints
- Understanding traits and size classes
Skill Level Intermediate
Learning LayoutTest for iOS Developmentwith Kyle Sherman1h 43m Intermediate
Designing iOS and Android Appswith Renata Phillippi1h 6m Intermediate
1. Basic Concepts in Auto Layout
2. Coding Constraints
3. The Visual Format Language
4. Stack Views
5. Advanced Layout
6. Size Classes
Next steps1m 42s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.