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

【Presenter notes版】SwiftUI における Color 周りの話 – Col...

Yuto Mizutani
November 08, 2019

【Presenter notes版】SwiftUI における Color 周りの話 – Color と Gradient から見る SwiftUI への苦悩 – / Include presenter notes: Understanding SwiftUI focused by Gradient color usages

https://speakerdeck.com/expensiveman/understanding-swiftui-focused-by-gradient-color-usages
の Presenter notes 版です。発表を聞いていない方へ向けた登壇メモを付記したバージョンになります。

Yuto Mizutani

November 08, 2019
Tweet

More Decks by Yuto Mizutani

Other Decks in Technology

Transcript

  1. SwiftUI ʹ͓͚Δ Color पΓͷ࿩ –– Color ͱ Gradient ͔ΒݟΔ SwiftUI

    ΁ͷۤ೰ –– YUMEMI.swift #4 ~Enjoy SwiftUI vol2~ @גࣜձࣾΏΊΈ SwiftUI ʹ͓͚Δ Color पΓͷ࿩ – Color ͱ Gradient ͔ΒݟΔ SwiftUI ΁ͷۤ೰ – / Understanding SwiftUI focused by Gradient color usages
  2. Rubens & Brueghel, The Garden of Eden with the fall

    of man ਆ࿩ʹ΋༻͍ΒΕ·͕͢ɼ ͜ͷ੺͍Ռ࣮͸ʮ৭ʯΛ௨ͯ͡ಈ෺ͱίϛϡχέʔγϣϯΛߦ͍·͢ɻ৭֮ͷൃୡͰ͢Ͷɻ ࠓճ͸ͦΜͳ৭ʹ͍ͭͯͷ͓࿩Ͱ͢ɻ (҆৺͍ͯͩ͘͠͞ɼՊֶऀ͸͠͹͠͹খൌͱͯ͠ਆ࿩Λ༻͍·͢ɻ)
  3. SwiftUI ʹ͓͚Δ Color पΓͷ࿩ YUMEMI.swift #4 ~Enjoy SwiftUI vol2~ @גࣜձࣾΏΊΈ

    –– Color ͱ Gradient ͔ΒݟΔ SwiftUI ΁ͷۤ೰ ––
  4. Summary • View •background(View) / foregroundColor(Color) • / ??? (View)

    • Shape •foregroundColor(Color) •fill(ShapeStyle) ^ ఻͍͑ͨ͜ͱ͸ 3఺ɼ1఺໨͸ ܕʹΑ੍ͬͯݶ͞ΕΔؔ਺͕͋Δͱ͍͏͜ͱɼ 2఺໨ɼෳ਺ͷ࣮૷ํ๏͕͋Δͱ͍͏͜ͱɻ ͦͯ͠3఺໨ɼView protocol ΁ͷద߹ʹΑ࣮ͬͯ૷ՄೳͰ͋Δؔ਺ʹ͸ɼ Ұ෦ͦͷ௨Γʹಈ͔ͳ͍΋ͷ͕͋Δͱ͍͏͜ͱɻ
  5. References • Color - SwiftUI | Apple Developer Documentation •

    foregroundColor(_:) - SwiftUI | Apple Developer Documentation • background(_:alignment:) - SwiftUI | Apple Developer Documentation • Gradient - SwiftUI | Apple Developer Documentation • LinearGradient - SwiftUI | Apple Developer Documentation • fill(_:style:) - SwiftUI | Apple Developer Documentation • Mac Catalyst - iOS - Human Interface Guidelines - Apple Developer • Cosmo/OpenSwiftUI - GitHub