我在按钮attributesTitle中添加了一些属性
let attr = NSMutableAttributedString(string: currTitle) attr.addAttribute(NsstrikethroughStyleAttributeName,value: 2,range: NSMakeRange(0,attr.length)) attr.addAttribute(NSForegroundColorAttributeName,value: UIColor.redColor(),attr.length)) currButton?.setAttributedTitle(attr,forState: UIControlState.normal)