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

Storyboardを積極的に使うべきか?その役割に基づく一考察

 Storyboardを積極的に使うべきか?その役割に基づく一考察

2017.06.23 iOS UI実装勉強会 @ Sansan

gaussbeam

June 26, 2017
Tweet

More Decks by gaussbeam

Other Decks in Programming

Transcript

  1. func chooseUiDevelopMethod(when situation: Situation) -> UIDevelopMethod { switch situation {

    case .developScreenTransition, .developSimpleView: return .byStoryboard case .developComplexView, .developLooksLikeOtherPlatformUI: return .byNibFilesAndCodess } } 
  2. 

  3. • ϝϦοτ • ը໘ભҠ΍ಋઢͷෳࡶ౓͕WYSIWYGʹͳΔ • ͲΜͳભҠ(Push? Modal?)Λ͢Δͷ͔΋ḷΓ΍͍͢ • σϝϦοτ •

    performSegue, prepareForSegue͔Βಀ͛ΒΕͳ͍…  ը໘ભҠͷ࣮૷ʹ͸ StoryboardΛετʔϦʔϘʔυͱͯ͠࢖͏
  4. 

  5. 

  6. • ϝϦοτ • ࠷ऴతͳը໘͕(ͦΕͳΓʹ)WYSIWYGʹͳΔ • ୹࣌ؒͰAuto LayoutରԠͰ͖Δ • σϝϦοτ •

    ࣗ༝౓͸௿͍(HIG͔Βͷҳ୤͸೉͍͠)  γϯϓϧͳViewͷ࣮૷ʹ͸ StoryboardΛInterface Builderͱͯ͠࢖͏
  7. 

  8. • ϝϦοτ • ը໘ͷߏ੒ཁૉ͕(ͦΕͳΓʹ)WYSIWYGʹͳΔ • Auto LayoutରԠ͸IBʹ೚ͤɼͩ͜ΘΓͷ࣮૷ՕॴͷΈίʔυͰ࣮ݱ • σϝϦοτ •

    ը໘ͷશମ૾/ΠϯλϥΫγϣϯ͸WYSIWYGʹͳΒͳ͍(Ͱ͖ͳ͍)  ෳࡶͳView΍ಠࣗͷςΠετͷUIΛ࣮૷͢Δ࣌͸ nibͱίʔυͰ࣮૷͢Δ