Xcode 8.3 Storyboard only ?

Discussion in 'Mac Programming' started by abcdefg12345, Mar 29, 2017.

  1. abcdefg12345 macrumors 6502


    Jul 10, 2013
    I noticed when creating a new cocoa project in Xcode 8.3 there is no option to pick storyboard or xib, instead the project automatically creates storyboard.

    did apple deprecate xib in favour of storyboard? I can't find any information anywhere about this.
  2. KALLT macrumors 601

    Sep 23, 2008
    It looks as though they removed the XIB-based project templates. You can still create new subclasses with accompanying XIB files though.
  3. hany macrumors newbie


    Apr 12, 2017
    You can start from a XIB-only clean project with Xcode 8.3.
    - create a new macOS cocoa app project
    - right click the left column (files tree) and select "New File..."
    - select "Main Menu" from the list then click "Next", then click "Create" on the dropdown view
    - on left column move to trash two files using right click: Main.storyboard and ViewController.swift
    - select the very first item of files tree to display target's general preferences
    - find the "Deployment Info" section of your preferences, then change "Main Interface" menu value selecting "MainMenu.xib"
    - almost done, now just select your xib then add an empty object to your xib then set its class to AppDelegate.
  4. 25ghosts macrumors 6502

    Jan 31, 2008
    Yes. The option is gone. I believe they removed it by accident. At least it makes no sense to me why they would remove that option on purpose.

    Lately the well-known Apple Quality has sunk so deep that Microsoft looks down on it instead of up
  5. KALLT macrumors 601

    Sep 23, 2008
    Because they want you to use storyboards, they have been encouraging developers for years. There are other examples where Apple discards the old in exchange for the new. Consider the Core Data template. New projects won’t start with the complete stack anymore, but with an NSPersistentContainer implementation. Likewise, there is no option to start a project without Interface Builder.
  6. 25ghosts macrumors 6502

    Jan 31, 2008
    OK - if this IS intended I'll bow and stand corrected. SBs ARE nice but overkill in many situations.
    Given the fact that the Cocoa App is nothing but a Template one could just delete the ViewControllers and SB and set up the app they way one wants to which is what I am doing. Having the SB Option was just a nice convenience thing saving me the developer the time of having to remove it every time I need to create a test project....
  7. canmor macrumors newbie


    Sep 18, 2017
    I google to here and found it works for me, thank you for your help!
    BTW: Do not forget to connect "File's Owner" to "AppDelegate" in "MainMenu.xib" after your mentioned last step.
  8. szymczyk macrumors regular

    Mar 5, 2006
    Xcode 9 brings back the Use Storyboards checkbox for new Cocoa application projects. I recommend updating to Xcode 9 if you prefer using xib files.
  9. superscape macrumors 6502a


    Feb 12, 2008
    East Riding of Yorkshire, UK
    That's good news. I've warmed to storyboards, but I think there's still a place for the old school way.
  10. 960design macrumors 68030

    Apr 17, 2012
    Destin, FL
    I use storyboards for simple stuff and code only for more complex layouts.

Share This Page

9 March 29, 2017