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
UICollectionView自動布局
Search
Hai Feng Kao
March 27, 2018
Programming
1
460
UICollectionView自動布局
UICollectionView layout和self-sizing cell的介紹
Hai Feng Kao
March 27, 2018
Tweet
Share
More Decks by Hai Feng Kao
See All by Hai Feng Kao
物件導向的文藝復興:用DCI重塑程式設計的藝術
haifengkao
0
140
模組化的Swift架構(一) Redux入門
haifengkao
0
150
模組化的Swift架構(二) DDD速成
haifengkao
0
870
日常生活中的腦殘
haifengkao
0
280
機器學習超入門
haifengkao
0
180
宅宅設計入門2
haifengkao
2
300
宅宅設計入門
haifengkao
5
320
Other Decks in Programming
See All in Programming
生成AI時代を勝ち抜くエンジニア組織マネジメント
coconala_engineer
0
37k
それ、本当に安全? ファイルアップロードで見落としがちなセキュリティリスクと対策
penpeen
6
1.7k
実は歴史的なアップデートだと思う AWS Interconnect - multicloud
maroon1st
0
300
Findy AI+の開発、運用におけるMCP活用事例
starfish719
0
2k
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
3.8k
大規模Cloud Native環境におけるFalcoの運用
owlinux1000
0
240
Unicodeどうしてる? PHPから見たUnicode対応と他言語での対応についてのお伺い
youkidearitai
PRO
0
270
AIで開発はどれくらい加速したのか?AIエージェントによるコード生成を、現場の評価と研究開発の評価の両面からdeep diveしてみる
daisuketakeda
1
360
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
160
2年のAppleウォレットパス開発の振り返り
muno92
PRO
0
180
안드로이드 9년차 개발자, 프론트엔드 주니어로 커리어 리셋하기
maryang
1
150
DevFest Android in Korea 2025 - 개발자 커뮤니티를 통해 얻는 가치
wisemuji
0
180
Featured
See All Featured
What’s in a name? Adding method to the madness
productmarketing
PRO
24
3.9k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
140
The Limits of Empathy - UXLibs8
cassininazir
1
200
Building AI with AI
inesmontani
PRO
1
610
WCS-LA-2024
lcolladotor
0
400
The Invisible Side of Design
smashingmag
302
51k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
132
19k
Ethics towards AI in product and experience design
skipperchong
1
160
The Curse of the Amulet
leimatthew05
0
6.8k
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
9.3k
Designing Experiences People Love
moore
143
24k
Transcript
UICollectionView⾃自動布局 Hai Feng Kao
UICollectionViewLayout • collectionViewContentSize: • layoutAttributesForElements(in:): • layoutAttributesForItem(at:): • shouldInvalidateLayout(forBoundsChange:):
會⾃自⼰己調整⼤大⼩小的cell • layoutAttributesForElements(in:): • layoutAttributesForItem(at:): • cellForItemAt: • preferredLayoutAttributesFitting(_:) •
shouldInvalidateLayout(forPreferred LayoutAttributes: withOriginalAttributes) • invalidationContext(forPreferredLayo utAttributes: withOriginalAttributes)
Reference and images credit • http://martiancraft.com/blog/2017/05/collection-view- layouts/