SlideShare a Scribd company logo
1 of 28
Download to read offline
Step Christopher @randomstep
Everything about Auto Layout
In 3 hours
Auto Layout Path to Mastery
In 5 minutes
2 Horizontal2 Vertical
Anchor Views
[demo of play controls]
[demo of play controls]
Debug (White Belt)
• Delete all constraints
• Start over
Tips (White Belt)
• Name your views in IB
• Name your constraints too!
• Think Locally (where should this view get its
size and position)
• Find a Sensei
Debug (Brown Belt)
• Preview pane: to see multiple sizes
• IB Structure and constraint inspectors: to
understand issues
• Debug View Hierarchy (Reveal and Spark
Inspector): to see runtime results
Tips (Brown Belt)
• Think Relatively
• Intrinsic Constraints
• Compression & Hugging
Debug (Black Belt)
• IB simulated sizes: force issues
• Cocoa Layout Instrument: inspect flow
Cocoa Layout Instrument
Cocoa Layout Instrument
Tips (Black Belt)
• Priorities: Preferred
• Max and Min
• Delete (don’t be afraid)
• Know when not to use
More Resources
• Apple: Adopting Auto Layout Guide
• WWDC Introduction to Auto Layout (2012 - 202)
• WWDC Mysteries of Auto Layout (2015, parts 1
and 2)
• Autolayout for everyone - NSSpain 2014
• Technical Note TN2154 - UIScrollView And
Autolayout
More Resources
• https://github.com/Masonry/Masonry
• https://github.com/floriankugler/FLKAutoLayout
• https://github.com/robotmedia/Lyt
• http://bignerdranch.com/blog
Big Nerd Ranch Guides
Thank You
step@bignerdranch.com @randomstep

More Related Content

Viewers also liked

Auto layout in i os 7
Auto layout in i os 7Auto layout in i os 7
Auto layout in i os 7
Claire Chang
 

Viewers also liked (9)

Auto layout in i os 7
Auto layout in i os 7Auto layout in i os 7
Auto layout in i os 7
 
Why use trace cloud to manage your requirements (includes audio)
Why use trace cloud to manage your requirements (includes audio)Why use trace cloud to manage your requirements (includes audio)
Why use trace cloud to manage your requirements (includes audio)
 
Introduction to auto layout
Introduction to auto layoutIntroduction to auto layout
Introduction to auto layout
 
Auto Layout Under Control @ Pragma conference 2013
Auto Layout Under Control @ Pragma conference 2013Auto Layout Under Control @ Pragma conference 2013
Auto Layout Under Control @ Pragma conference 2013
 
Swift, a quick overview
Swift, a quick overviewSwift, a quick overview
Swift, a quick overview
 
Auto-Layout in iOS 7
Auto-Layout in iOS 7Auto-Layout in iOS 7
Auto-Layout in iOS 7
 
Auto Layout on Xcode 5
Auto Layout on Xcode 5Auto Layout on Xcode 5
Auto Layout on Xcode 5
 
Introduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/MacIntroduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/Mac
 
Code Review for iOS
Code Review for iOSCode Review for iOS
Code Review for iOS
 

Similar to Auto Layout Path to Mastery - Lightning Talk

Similar to Auto Layout Path to Mastery - Lightning Talk (20)

Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"
Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"
Алексей Ященко и Ярослав Волощук "False simplicity of front-end applications"
 
Adjusting to Auto Layout (Tutorial / Tips for iOS Auto Layout)
Adjusting to Auto Layout (Tutorial / Tips for iOS Auto Layout)Adjusting to Auto Layout (Tutorial / Tips for iOS Auto Layout)
Adjusting to Auto Layout (Tutorial / Tips for iOS Auto Layout)
 
Test driven development with Jasmine
Test driven development with JasmineTest driven development with Jasmine
Test driven development with Jasmine
 
URUG Ruby on Rails Workshop - Sesssion 5
URUG Ruby on Rails Workshop - Sesssion 5URUG Ruby on Rails Workshop - Sesssion 5
URUG Ruby on Rails Workshop - Sesssion 5
 
Technology-Driven Development: Using Automation and Development Techniques to...
Technology-Driven Development: Using Automation and Development Techniques to...Technology-Driven Development: Using Automation and Development Techniques to...
Technology-Driven Development: Using Automation and Development Techniques to...
 
Take Pride in Your Code - Test-Driven Development
Take Pride in Your Code - Test-Driven DevelopmentTake Pride in Your Code - Test-Driven Development
Take Pride in Your Code - Test-Driven Development
 
Beautiful Builds - Roy Osherove at Microsoft Swit
Beautiful Builds - Roy Osherove at Microsoft SwitBeautiful Builds - Roy Osherove at Microsoft Swit
Beautiful Builds - Roy Osherove at Microsoft Swit
 
Android UI Testing with Espresso
Android UI Testing with EspressoAndroid UI Testing with Espresso
Android UI Testing with Espresso
 
Ropossum: A Game That Generates Itself
Ropossum: A Game That Generates ItselfRopossum: A Game That Generates Itself
Ropossum: A Game That Generates Itself
 
Chapter 12 - Activity Intent
Chapter 12 - Activity  IntentChapter 12 - Activity  Intent
Chapter 12 - Activity Intent
 
Toad tipstricksexpertinsight
Toad tipstricksexpertinsightToad tipstricksexpertinsight
Toad tipstricksexpertinsight
 
A tale of 3 databases
A tale of 3 databasesA tale of 3 databases
A tale of 3 databases
 
User Story Mapping
User Story MappingUser Story Mapping
User Story Mapping
 
ORM Pink Unicorns
ORM Pink UnicornsORM Pink Unicorns
ORM Pink Unicorns
 
Untangling11
Untangling11Untangling11
Untangling11
 
Automated testing in javascript
Automated testing in javascriptAutomated testing in javascript
Automated testing in javascript
 
Sami Laiho - Black belt troubleshooting windows 8.1
Sami Laiho - Black belt troubleshooting windows 8.1Sami Laiho - Black belt troubleshooting windows 8.1
Sami Laiho - Black belt troubleshooting windows 8.1
 
WCAG 2.1 Made Easier for Non-Accessibility Professionals 2019-03-15
WCAG 2.1 Made Easier for Non-Accessibility Professionals 2019-03-15WCAG 2.1 Made Easier for Non-Accessibility Professionals 2019-03-15
WCAG 2.1 Made Easier for Non-Accessibility Professionals 2019-03-15
 
Effectively Using UI Automation
Effectively Using UI AutomationEffectively Using UI Automation
Effectively Using UI Automation
 
Kanban in Action Workshop
Kanban in Action WorkshopKanban in Action Workshop
Kanban in Action Workshop
 

Recently uploaded

electrical installation and maintenance.
electrical installation and maintenance.electrical installation and maintenance.
electrical installation and maintenance.
benjamincojr
 
21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx
rahulmanepalli02
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdf
Kira Dess
 

Recently uploaded (20)

Diploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdfDiploma Engineering Drawing Qp-2024 Ece .pdf
Diploma Engineering Drawing Qp-2024 Ece .pdf
 
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdfInstruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
Instruct Nirmaana 24-Smart and Lean Construction Through Technology.pdf
 
CLOUD COMPUTING SERVICES - Cloud Reference Modal
CLOUD COMPUTING SERVICES - Cloud Reference ModalCLOUD COMPUTING SERVICES - Cloud Reference Modal
CLOUD COMPUTING SERVICES - Cloud Reference Modal
 
Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...Developing a smart system for infant incubators using the internet of things ...
Developing a smart system for infant incubators using the internet of things ...
 
Independent Solar-Powered Electric Vehicle Charging Station
Independent Solar-Powered Electric Vehicle Charging StationIndependent Solar-Powered Electric Vehicle Charging Station
Independent Solar-Powered Electric Vehicle Charging Station
 
electrical installation and maintenance.
electrical installation and maintenance.electrical installation and maintenance.
electrical installation and maintenance.
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)
 
Seismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
Seismic Hazard Assessment Software in Python by Prof. Dr. Costas SachpazisSeismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
Seismic Hazard Assessment Software in Python by Prof. Dr. Costas Sachpazis
 
analog-vs-digital-communication (concept of analog and digital).pptx
analog-vs-digital-communication (concept of analog and digital).pptxanalog-vs-digital-communication (concept of analog and digital).pptx
analog-vs-digital-communication (concept of analog and digital).pptx
 
21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx21P35A0312 Internship eccccccReport.docx
21P35A0312 Internship eccccccReport.docx
 
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdfInvolute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
Involute of a circle,Square, pentagon,HexagonInvolute_Engineering Drawing.pdf
 
15-Minute City: A Completely New Horizon
15-Minute City: A Completely New Horizon15-Minute City: A Completely New Horizon
15-Minute City: A Completely New Horizon
 
Basics of Relay for Engineering Students
Basics of Relay for Engineering StudentsBasics of Relay for Engineering Students
Basics of Relay for Engineering Students
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptx
 
Autodesk Construction Cloud (Autodesk Build).pptx
Autodesk Construction Cloud (Autodesk Build).pptxAutodesk Construction Cloud (Autodesk Build).pptx
Autodesk Construction Cloud (Autodesk Build).pptx
 
Interfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdfInterfacing Analog to Digital Data Converters ee3404.pdf
Interfacing Analog to Digital Data Converters ee3404.pdf
 
Artificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdfArtificial intelligence presentation2-171219131633.pdf
Artificial intelligence presentation2-171219131633.pdf
 
UNIT-2 image enhancement.pdf Image Processing Unit 2 AKTU
UNIT-2 image enhancement.pdf Image Processing Unit 2 AKTUUNIT-2 image enhancement.pdf Image Processing Unit 2 AKTU
UNIT-2 image enhancement.pdf Image Processing Unit 2 AKTU
 
Insurance management system project report.pdf
Insurance management system project report.pdfInsurance management system project report.pdf
Insurance management system project report.pdf
 
Intro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney UniIntro to Design (for Engineers) at Sydney Uni
Intro to Design (for Engineers) at Sydney Uni
 

Auto Layout Path to Mastery - Lightning Talk