NSAttributedString ignores Autoshrink and numberOfLines for UILabel (iOS 6)

I found a way to do this:

label.adjustsFontSizeToFitWidth = true
label.attributedText = attributedString
label.lineBreakMode = .ByTruncatingTail // this did the trick!

It only works if the third line is set after setting the attributed string. It seems like the attributed string overrides line break behavior when set (among other things).

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)