Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Taming AutoLayout
Search
Sergio Utama
March 21, 2016
Programming
0
48
Taming AutoLayout
Initially presented during MyCocoaheads (
https://www.facebook.com/groups/mycocoaheads/
) meetup
Sergio Utama
March 21, 2016
Tweet
Share
More Decks by Sergio Utama
See All by Sergio Utama
Easy Way to Improve ReactNative
sergioutama
0
270
From try! Swift Tokyo 2017
sergioutama
0
64
Migrating to Swift 3
sergioutama
0
55
10 Things I learned while freelancing
sergioutama
0
59
iOS Video Player
sergioutama
0
90
Tribute to Mantle
sergioutama
0
31
Mobile Analytics
sergioutama
0
46
Other Decks in Programming
See All in Programming
DevinとClaude Code、SREの現場で使い倒してみた件
karia
1
1.1k
AI時代のシステム設計:ドメインモデルで変更しやすさを守る設計戦略
masuda220
PRO
6
1.1k
Vuetify 3 → 4 何が変わった?差分と移行ポイント10分まとめ
koukimiura
0
170
AIコードレビューの導入・運用と AI駆動開発における「AI4QA」の取り組みについて
hagevvashi
0
530
『Kubernetes ☸️ で実践する Platform Engineering 』を最高速度で読み抜いたる!!👊🏻
hiroki_hasegawa
0
100
脱 雰囲気実装!AgentCoreを良い感じにWEBアプリケーションに組み込むために
takuyay0ne
3
370
それはエンジニアリングの糧である:AI開発のためにAIのOSSを開発する現場より / It serves as fuel for engineering: insights from the field of developing open-source AI for AI development.
nrslib
1
430
ポーリング処理廃止によるイベント駆動アーキテクチャへの移行
seitarof
3
1.1k
RAGでハマりがちな"Excelの罠"を、データの構造化で突破する
harumiweb
9
3k
Goの型安全性で実現する複数プロダクトの権限管理
ishikawa_pro
2
500
守る「だけ」の優しいEMを抜けて、 事業とチームを両方見る視点を身につけた話
maroon8021
3
1.2k
AI時代の脳疲弊と向き合う ~言語学としてのPHP~
sakuraikotone
1
1.4k
Featured
See All Featured
How GitHub (no longer) Works
holman
316
150k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.7k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
64
52k
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
1.9k
Into the Great Unknown - MozCon
thekraken
40
2.3k
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
0
790
Typedesign – Prime Four
hannesfritz
42
3k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
180
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
250
Transcript
Taming AutoLayout @sergioutama
Thinking Constraint “ It’s relationship between one view with another
“
Center Y Center X height width baseline leading trailing top
bottom A
Autolayout Component Priority Hugging and Compression
AutoLayout Frame ♥
view.translatesAutoresizingMaskIntoConstraints Follow the rules setNeedsUpdateConstraints() layoutSubviews() viewdidLayoutSubviews() autoresize layout pass
setNeedsLayout() => super.setNeedsLayout()
Follow the rules “ superview only change it’s direct subviews
“
Debug Autolayout ensure x, y, & size ensure priority set
constraint identifier set view accessibility identifier
DEMO
Reference wwdc2015/218 wwdc2015/219 Apple AutoLayout Programming Guide
QA
Thank you @sergioutama