gpt4 book ai didi

ios - TTTAttributedLabel linebreakmode 在 iOS6 中被破坏

转载 作者:可可西里 更新时间:2023-11-01 06:22:06 25 4
gpt4 key购买 nike

如果我在 TTTAttributedLabel 示例应用“Espresso”中将 linebreakmode 设置为 truncation tail超过 3 行。行数设置为零。我错过了什么?在我注意到 Espresso 应用程序中的这种行为后,我可以不再担心我自己的应用程序中代码的错误。有什么建议么?谢谢!

最佳答案

我目前遇到了同样的问题。在实际设置文本之前尝试设置 LineBreakMode。例如:

TTTAttributedLabel* descriptionLabel = [[TTTAttributedLabel alloc] initWithFrame:CGRectMake(20, 120, 280, expectedSize.height)];
descriptionLabel.lineBreakMode = UILineBreakModeWordWrap;
descriptionLabel.numberOfLines = 0;
descriptionLabel.text = description;

关于ios - TTTAttributedLabel linebreakmode 在 iOS6 中被破坏,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15684370/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com