目前,我还没有找到在iOS 12.0上实现此功能的方法。我已尝试像这样设置栏色调。
[mailController.navigationBar setTintColor:[UIColor whiteColor]];
然后,我尝试使用以下代码设置标题文本属性
[mailController.navigationController.navigationBar setTitleTextAttributes:
@{NSForegroundColorAttributeName:[UIColor WhiteColor]};
我在StackOverflow上尝试了更多的选项,但它们都没有起作用。我希望有人找到一种可靠的方法来更改导航栏标题文本颜色。无论我做什么,它都保持为黑色。栏按钮的颜色正确更改,但导航栏标题没有。