【发布时间】:2018-10-20 13:44:10
【问题描述】:
我知道这个问题已经被问过很多次了,但是我阅读的答案都没有帮助我解决我的问题...
在我的 iOS 应用程序中,我正在使用默认框架 (UIGraphicsBeginPDFContextToFile...) 生成 PDF 文件。 一切正常,我可以更改文本颜色、基础样式等。
但我没有敲弦。
这是我的代码:
[toBeConfirmedText addAttributes:@{ NSBaselineOffsetAttributeName: @(0), NSStrikethroughStyleAttributeName: @(NSUnderlineStyleThick), NSStrikethroughColorAttributeName: [UIColor redColor] } range:NSMakeRange(0, toBeConfirmedText.length)];
但这不起作用...
有人有想法吗?
【问题讨论】:
标签: ios text nsattributedstring strikethrough