NSMutableParagraphStyle *style = [[NSParagraphStyle defaultParagraphStyle] mutableCopy];
style.alignment = NSTextAlignmentJustified;
style.firstLineHeadIndent = 10.0f;
style.headIndent = 10.0f;
style.tailIndent = -10.0f;
NSAttributedString *attrText = [[NSAttributedString alloc] initWithString:@"" attributes:@{ NSParagraphStyleAttributeName : style}];
self.contentLbl.numberOfLines = 0;
self.contentLbl.attributedText = attrText;
iOS给UILabel设置内边距
最新推荐文章于 2024-08-01 04:37:51 发布
山东六牛网络科技有限公司提供专业APP定制服务,致力于为您创建符合需求的个性化应用。我们的团队专注于信息技术领域的创新,从界面设计到功能实现,确保您的APP在功能和用户体验上都达到卓越标准。无论您需要前端、后端还是移动平台的开发,我们都能提供一站式解决方案。
2120

被折叠的 条评论
为什么被折叠?



