understanding stack views

16
Understanding Stack Views iOS Development

Upload: henrique-morbin

Post on 08-Feb-2017

48 views

Category:

Mobile


0 download

TRANSCRIPT

Page 1: Understanding stack views

Understanding Stack Views

iOS Development

Page 2: Understanding stack views

Topics● History● Stack Views● Comparison● Properties

○ Alignment○ Distribution○ Spacing

● Some points

Page 3: Understanding stack views

HistoryWith WWDC 2015, and iOS 9, Apple introduced a special type of view called Stack View.

Page 4: Understanding stack views

Stack Views are...

Auto Layout without Constraints

https://developer.apple.com/library/content/documentation/UserExperience/Conceptual/AutolayoutPG/AutoLayoutWithoutConstraints.html

Page 5: Understanding stack views

Stack Views

Page 6: Understanding stack views

Constraints

Page 7: Understanding stack views

Constraints

Page 8: Understanding stack views

Comparison

Page 9: Understanding stack views
Page 10: Understanding stack views

Alignment

Page 11: Understanding stack views

Alignment

Page 12: Understanding stack views

Distribution

Page 13: Understanding stack views

Spacing

Page 14: Understanding stack views

Some points● It is not a visual element;● Stack view only manage the layout of its content, so you are responsible to

define the position and (optionally) the size of the stack;● You can nest stack views;

Page 15: Understanding stack views

Nested Stack Views