Upgrade to Pro — share decks privately, control downloads, hide ads and more …

iOS Animations with Auto Layout

Realm
October 05, 2015

iOS Animations with Auto Layout

Presented by Marin Todorov at GOTO Copenhagen 2015

Realm

October 05, 2015
Tweet

More Decks by Realm

Other Decks in Programming

Transcript

  1. Stack Overflow Q: How to do this one animation thing

    in my app?
 
 A: Include Bloated.framework by Super Awesome Ninja Dev 
 and paste:
 createANM().move().byX(20).byY(10).fadeWithTint().etc().etc() 
 Q: Accepted! Works!
  2. AutoLayout UIView1 UIView2 Constraint Width Constraint Height Constraint CenterX Constraint

    MarginY Constraint Ratio Constraint Height Constraint Vert. Space Layout Hierarchy UIView1.center UIView1.bounds UIView2.center UIView2.bounds UIView1.height = UIView2.height * 0.5 + 100
  3. AutoLayout VC pushed VC popped orientation
 change keyboard
 pops up

    change
 constraint AutoLayout AutoLayout AutoLayout Internal & External changes loadView()
  4. AutoLayout UIView1 UIView2 Constraint Width Constraint Height Constraint CenterX Constraint

    MarginY Constraint Ratio Constraint Height Constraint Vert. Space Layout Hierarchy UIView1.center UIView1.bounds UIView2.center UIView2.bounds UIView1.height = UIView2.height * 0.5 + 100
  5. UIStackView Button Constraint Width Constraint Height Constraint CenterX Constraint MarginY

    Constraint Ratio Constraint Height Constraint Vert. Space AutoLayout Text horizontal/vertical centered margin space consult prev. slides