如何更改导航栏的后退按钮的字体.
后退按钮是"后退"或前一个视图控制器的标题.
我认为这viewDidLoad会奏效:
navigationController?.navigationItem.leftBarButtonItem?.setTitleTextAttributes([NSFontAttributeName: UIFont(name: "FONTNAME", size: 20)!], forState: UIControlState.Normal)
Run Code Online (Sandbox Code Playgroud)
但是leftBarButton?可选的退货nil.
cocoa-touch uinavigationbar uinavigationcontroller ios swift