UILabels and Unicode

后端 未结 2 1084
一整个雨季
一整个雨季 2021-01-23 11:11

I know questions similar to this have been asked, but I haven\'t found a satisfactory answer.

I\'m trying to create a UILabel to display an equation. I don\'t like havin

相关标签:
2条回答
  • 2021-01-23 11:23

    You can use %C format specifier for unicode.

    myLabel.text = [NSString stringWithFormat:@"String with unicode %C", 0x207F];
    
    0 讨论(0)
  • 2021-01-23 11:35

    you can assign a unicode in uilabel as follows -

    [yourLabel settext:@"\u207F and \u2099"];
    
    0 讨论(0)
提交回复
热议问题