Xcode 6界面构建器不显示自定义类

Lai*_*ilo 6 xcode interface-builder ios swift xcode6

我的Xcode 6.3界面构建器中有错误.当我创建一个新的自定义类,并希望将其添加到界面构建器自定义类字段.它不可用.我确实使用Swift作为语言.

我尝试了什么:

  • 删除派生数据
  • 重新安装Xcode
  • 清洁项目
  • 创建了新项目
  • 类名与文件名相同
  • 超类和接口构建器类是相同的

什么都没有成功;-(不知道它可能是什么?

在此输入图像描述

在此输入图像描述

在此输入图像描述

Chr*_*cou -4

TimerCVC 不是 UIViewController 的子类

按 ctrl-n -> 在左侧面板上选择 iOS -> Source -> Cocoa Touch Class -> 从下拉菜单中选择 UIViewController -> 然后填写名称字段(Xcode 自动完成并在末尾添加 ViewController)。

它应该看起来像这样

import UIKit

class TimerViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        // Do any additional setup after loading the view, typically from a nib.
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }


}
Run Code Online (Sandbox Code Playgroud)