Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
チュートリアルから一歩前進する為のAutoLayout Tips
Search
Yutaka Shimada
January 26, 2019
Programming
95
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
チュートリアルから一歩前進する為のAutoLayout Tips
2019/01/26に行われたiPhone Dev Sapporoで発表した時の資料です。
Yutaka Shimada
January 26, 2019
Transcript
27 slides
νϡʔτϦΞϧ͔Β Ұาલਐ͢Δҝͷ AutoLayout Tips iPhone Dev Sapporo 2019/01/26 ͠·ͩΏ͔ͨˏShimayuSti
iPhoneΞϓϦΛॳϦϦʔεͨ͠
ൃදऀˏ͠·ͩΏ͔ͨ @ShimayuSti shimayu22 @shimayu_sti ೣࣂ͍࠺ࢠ࣋ͪඇΤϯδχΞ ΞϓϦ࡞Γ͓͡͞Μɻ ৄ্͘͠هΞΧϯτ͔Β
ϋϜԠԉՎ҉هΞϓϦʢඇެࣜʣ
͓ɺΞϓϦͷ༷ࢠ͕ɾɾɾ
iPhone SE(4Πϯν) ʂ ʂ ʂ ʂ
iPhone XS Max(6.5Πϯν) ʂ ʂ ʂ ʂ ʂ
࣮ػʢiPhone6SʣͰ͔ͬΓ ֬ೝͯͨ͠πέ͕ɾɾɾ
None
AutoLayoutͱ • AutoLayoutɺϏϡʔʹઃఆ͞Ε͍ͯΔ੍ ʹج͍ͮͯɺϏϡʔ֊ͷͯ͢ͷϏϡʔͷ αΠζͱҐஔΛಈతʹܭࢉ͠·͢ • ը໘αΠζ͝ͱʹҰͭͣͭը໘Λ༻ҙ͠ͳ͘ ͍͍ͯʂ
1ɽͱͳΔViewΛ༻ҙ͢Δ
None
2ɽ͍ۙUIಉ࢜Ͱ੍Λ͚ͭΔ ʂ
None
ͪΐͬͱҰଉ
3ɽSafeAreaΛߟྀ͢Δ 4BGF"SFBʹ ࠂ͕ඃͬͯΔ
SafeAreaͱ https://developer.apple.com/design/human-interface-guidelines/ios/visual- design/adaptivity-and-layout/
ίʔυͰSafeAreaΛऔಘ͢Δ override func viewDidAppear(_ animated: Bool) { let admobView =
GADBannerView(adSize: kGADAdSizeBanner) if #available(iOS 11.0, *){ //iOS11Ҏ্Ͱ͋ΕSafeAreaΛऔಘͰ͖Δ admobView.frame.origin = CGPoint(x: 0, y: self.view.frame.size.height - admobView.frame.height - self.view.safeAreaInsets.bottom) }else{ admobView.frame.origin = CGPoint(x: 0, y: self.view.frame.size.height - admobView.frame.height) } ʙུʙ } ࢀߟɿhttps://techno-monkey.com/app-develop-iphonex-safearea/
None
StoryboardͰSafeAreaΛج४ʹͰ͖·͢
4ɽҰ୴ఘΊΔ ը૾ΛॏͶΔͱௐ ͕͔ͬͨ͠ͷͰ ࠓճఘΊͨ
5ɽޙಓʹௐ͢Δ ʮUnderstanding Auto LayoutʯΛΑ͘ಡΜͰɺ ࣮ࡍʹ੍Λࢼͯ͠Έͯɺ https://developer.apple.com/library/archive/documentation/UserExperience/ Conceptual/AutolayoutPG/AnatomyofaConstraint.html#//apple_ref/doc/uid/ TP40010853-CH9-SW1 ͳΜͱ͔͢Δɻ
https://twitter.com/llminatoll/status/ 1042368602068795393 AutoLayout
օ͞Μͷ࣮ػͰ͓ࢼ͍ͩ͘͠͞ ʢએʣ ͘͠ ʮϋϜɹԠԉՎʯ Ͱݕࡧ
ࠓޙͷ՝ • େ͖͍ը໘Λ༗ޮ׆༻ Ͱ͖͍ͯͳ͍ • จࣈαΠζ • ϘλϯαΠζ • ന͍ͱ͜Ζ͕ଟ͍
͝੩ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠ Githubʹը໘मਖ਼લͷϓϩδΣΫτ͕ஔ͍ͯ͋Γ ·͢ͷͰɺAutoLayoutͷ࿅शʹͬͯɺͲ͏ͧɻ https://github.com/shimayu22/hamuouenka- trial-production
ࢀߟ • https://qiita.com/t-matsuda820/items/bf2ea89b8395bc4532c2 • https://qiita.com/rd0501/items/18fe132d8ddf8ac4b589 • https://qiita.com/tomohisaota/items/f8857d01f328e34fb551 • https://developers.google.com/admob/ios/x-ad-rendering •
https://techno-monkey.com/app-develop-iphonex-safearea/ • https://qiita.com/reima21/items/ef02b865496528f0dc6b
Other Decks in Programming
See All in Programming
なぜ私たちは「現時点では」KMPの導入を見送ったのか
chigichan24
1
650
あなたはMCPの機能を、まだ知らない。
4geru
1
750
imagewebp()の向こう側: WebPはなぜ JPEG・PNGより軽いのか
yuzneri
0
160
baseline으로 마이그레이션, 리팩토링 안전하게 맡기기
fornewid
1
1.1k
TS 7.0 で baseUrl が使えなくなった今、パスエイリアスをどうするか
bicstone
2
860
Distance field of Julia set
kinakomoti321
0
330
protojson における文字化けの扱い
kazuki1023
0
470
joyful-journey-spring-boot.pdf
hollycummins
0
130
[DroidKnights 2026] Workflow AX: From Auto-Documented Policies to E2E Testing
raeminkang
0
610
Growing PicoRuby's Ecosystem on ESP32
yuuu
2
150
マルチプロダクトSaaSの アプリ一覧を速くする——複数プロダクトにまたがる「権限行脚」を減らすまで #techramen26conf
mktakuya
1
260
テスト駆動開発から学ぶ 達人プログラマーの型 / TechRAMEN 2026 Conference
a_okui
0
3.2k
Featured
See All Featured
Optimising Largest Contentful Paint
csswizardry
37
4k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
640
For a Future-Friendly Web
brad_frost
184
11k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
610
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
35k
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
1.1k
A Tale of Four Properties
chriscoyier
163
24k
Amusing Abliteration
ianozsvald
1
400
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
490
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.3k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.8k