问题描述
我需要显示具有两个属性的属性字符串-BaselineOffset和underlinestyle。
let text = NSMutableAttributedString(string: "qwe 111 222 333 444 555 aaa ppp 666 777 888 9999 000 zzzz")
text.addAttribute(.underlinestyle,value: NSUnderlinestyle.single.rawValue,range: NSRange(location: 10,length: 5))
text.addAttribute(.baselineOffset,value: 1,range: NSRange(location: 0,length: text.length))
标签宽度为200,文本需要三行才能适合。但是标签不显示最后一行。即使我的身高异常高,它仍然无法正常工作。我不明白为什么这两个属性不能一起使用。谢谢您的帮助
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)