0

I found that UILabel use set the line spacing, he no longer shows the size of the ellipsis even if he is not enough, I would like to know how to add the ellipsis

    let message:NSString = "Perhaps you are an average student with average intelligence." 

    let attributedString = NSMutableAttributedString(string: str as String)
    let paragraphStyle = NSMutableParagraphStyle();
    paragraphStyle.lineSpacing = 5
    attributedString.addAttribute(NSParagraphStyleAttributeName, value: paragraphStyle, range: NSMakeRange(0, message.length))
    detailLabel.attributedText = attributedString
aaron
  • 11
  • 3

1 Answers1

0

Do you mean rounded corners? If you want perfectly rounded corners add

detailLabel.layer.cornerRadius = detailLabel.frame.height / 2
NSGangster
  • 2,397
  • 12
  • 22