此处已经回答了更改 UIAlertViewController对象的消息和标题的字体:如何在UIAlertController中更改UIAlertAction的字体大小和颜色.
但我想知道如何使用Swift更改UIAlertAction(iOS8 +)标题上的字体.不幸的是,UIAlertAction实例没有一个名为"attributionTitle"的属性,就像UIAlertController一样.
我要扩展以更改字体的代码如下:
let alertAction = UIAlertAction(title: "Got It!", style: .Default, handler: nil)
alertController.addAction(alertAction)
Run Code Online (Sandbox Code Playgroud)
任何想法将不胜感激.