使用swift更改拉动以刷新文本颜色

时间:2014-09-13 12:07:43

标签: colors swift pull-to-refresh

我可以在我的应用中刷新。

如何更改attributionTitle的文本颜色?

 refresher.attributedTitle = NSAttributedString(string: "hey ! is there something new ?")

1 个答案:

答案 0 :(得分:9)

尝试

var attr = [NSForegroundColorAttributeName:UIColor.greenColor()]
refresher.attributedTitle = NSAttributedString(string: "hey ! is there something new ?", attributes:attr)