Xcode 6.3 freezes/hangs after opening XIB file

前端 未结 10 1311
离开以前
离开以前 2020-12-12 13:35

After upgrading to Xcode 6.3 (release version), Xcode now freeze every time I open a XIB/Storyboard file that includes an IB_DESIGNABLE view that uses a cu

相关标签:
10条回答
  • 2020-12-12 13:48

    Another workaround is to change the file extensions to all of your font files and load the changed file names from Info.plist. This way you can keep IBDesignables and still use your custom fonts, but wont be able to see them in the Font Picker in Interface Builder.

    All custom fonts that were peviously set from Interface Builder will continue to work, but in order to change them or to set another custom fonts, you will have to do it either from code or to modify the Storyboard or Nib files from text editor in order to set the font name.

    0 讨论(0)
  • 2020-12-12 13:58

    As a workaround,I just commented out all the @IBDesignable markup in my handful of custom components that use this. When I did that, yes I lose ability to tweak the settings in Interface Builder, but it allowed me to at least open the .xib files w/out XCode crashing.

    I will simply un-comment those @IBDesignable lines when Apple comes up w/ a fix.

    0 讨论(0)
  • 2020-12-12 14:01

    Same problem for me. Removing IB_DESIGNABLE fixes the problem.. Going back to 6.2 doesn't work for me as I'm testing apps on device with iOS 8.3 - Xcode 6.2 can't run apps on devices with iOS 8.3 :(

    0 讨论(0)
  • 2020-12-12 14:02

    Xcode 6.3.1 fixes the problem with custom fonts and IB_DESIGNABLE views in a Storyboard. Update via the Mac App Store, and you should be good.

    0 讨论(0)
  • 2020-12-12 14:05

    Xcode 8.1 - if you have a view with Navigation (in my case it was top Bar opaque Navigation Bar), just try to set property "top Bar" to None.

    0 讨论(0)
  • 2020-12-12 14:06

    Response from Apple: Link to Developer Forums on Apple

    Thank you all for your reports. We are tracking this on our end and working hard to resolve it. Unfortunately we don't have a great workaround, but here are two options to get you going:

    If Xcode is hanging on launch because a storyboard/XIB using a custom font/IBDesignable was previously open: remove the "UserInterfaceState.xcuserstate" file inside the xcodeproj of the project you are opening, it would be at a path like this: My App.xcodeproj/project.xcworkspace/xcuserdata/yourusername.xcuserdatad/UserInterfaceState.xcuserstate

    If you really need to edit the storyboard/XIB file containing the custom font with Xcode 6.3:

    1. Make a copy of your storyboard/XIB file as a backup
    2. Open the storyboard/XIB file in a text editor
    3. Remove XML tags named "fontDescription" that reference your custom font, for example: . Removing this tag will revert the font to the standard system font.
    4. Make outlets to the objects using the custom font and at runtime set the font of those objects to your custom font, for example in an override of viewDidLoad or awakeFromNib on your view controller

    IMPORTANT NOTE: we never recommend hand editing storyboard/XIB files. However we recognize this issue is preventing many of you from editing your documents and wanted to provide a workaround with the caveat that any hand editing may result in corruption of your document.

    0 讨论(0)
提交回复
热议问题