Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/99.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
iOS 13大标题在滚动之前不可见_Ios_Uinavigationbar - Fatal编程技术网

iOS 13大标题在滚动之前不可见

iOS 13大标题在滚动之前不可见,ios,uinavigationbar,Ios,Uinavigationbar,UINavigationBar仅当我在已显示的导航控制器上显示导航控制器时才会显示异常行为。大标题在我滚动之前不可见。它只是为大标题显示空白。这就是我设置导航栏的方式。没什么了不起的 注意:下面的代码是在导航控制器的子类中编写的 let appearance = UINavigationBarAppearance() appearance.backgroundColor = UIColor.appNavBarColor() appearance.titleTextAttributes = [NS

UINavigationBar
仅当我在已显示的导航控制器上显示导航控制器时才会显示异常行为。大标题在我滚动之前不可见。它只是为大标题显示空白。这就是我设置导航栏的方式。没什么了不起的

注意:下面的代码是在导航控制器的子类中编写的

let appearance = UINavigationBarAppearance()
appearance.backgroundColor = UIColor.appNavBarColor()
appearance.titleTextAttributes = [NSAttributedString.Key.font : UIFont.boldSystemFont(ofSize: 17.0),
        NSAttributedString.Key.foregroundColor : UIColor.white]
appearance.largeTitleTextAttributes = [NSAttributedString.Key.foregroundColor : UIColor.white]
navigationBar.standardAppearance = appearance
navigationBar.scrollEdgeAppearance = appearance
这就是它在显示
UINavigationController
时的显示方式