学Swift挣美金

Swift 教程之笔记App01项目基础环境搭建

2019-05-18  本文已影响10人  iCloudEnd

步骤

  1. 创建一个项目,名称为NotesiOSApp
  2. 删除storyboard 修改info.plist
  3. ViewController添加view.backgroundColor = .yellow
  4. 修改ViewController名称FoldersController
  5. 添加nav导航条
  6. 添加导航条标题,并设置大标题
 UINavigationBar.appearance().prefersLargeTitles = true
        let navController = UINavigationController(rootViewController: FoldersController())
        window = UIWindow()
        window?.makeKeyAndVisible()
        window?.rootViewController = navController
  view.backgroundColor = .yellow
  navigationItem.title = "Folders"

运行效果

Jietu20190518-091822@2x.jpg
上一篇下一篇

猜你喜欢

热点阅读