I have one UILabel
which shows strikethrough text (e.g. text). It was working fine till iOS 13. In iOS 14, that strikethrough line is not showing, i.e. instead of 'text', it is coming as 'text'. This is the code I used:
let totalString: String = "some text"let strikeString: String = "text" //string to be made strikethroughlet totalNsString = totalString as NSStringlet attributeString = NSMutableAttributedString(string: totalString)attributeString.addAttribute(NSAttributedString.Key.strikethroughStyle, value: 2, range: totalNsString.range(of: strikeString))label.attributedText = attributeString
Desired Output:
some
text
Current Outout:
some text
Can anyone please tell me is there anything I need to change or anything else. TIA.