I am trying to find a solution for it and confuse how to display the third power / cube in UILabel. I tried to find the answer in a previously asked question, but none of them were helpful.
Questions I tried to get answers to:
how-to-show-superscript-for-registered-symbol
UILabel and superscript
If I need to use unichars, how can I use them for add-ons?
Thanks..
You need to specify a unicode character for superscript three:
NSInteger number = 10; NSString *cubedSymbol = @"\u00B3"; NSString *tenCubed = [NSString stringWithFormat:@"%d%@",number,cubedSymbol];
Much more fun will be here
Another solution would be to use the Core Text framework to draw an NSAttributedString with the kCTSuperscriptAttributeName attribute in the section of the string you want to make superscript. The result is more work, including a custom drawing and more, but more flexible than using Unicode characters.
NSAttributedString
kCTSuperscriptAttributeName
Here is a blog post that I found with more information: http://iphonedevelopment.blogspot.com/2011/03/attributed-strings-in-ios.html
NSAttributedString on Mac OS X has many nice uses built into AppKit, but Apple hasn't made it easy to work with UIKit for iOS.
Source: https://habr.com/ru/post/1384894/More articles:https://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1384889/what-are-requirements-to-use-couchdb-on-android&usg=ALkJrhjiC8mtikAENWKjHHajCvC57SEc_gWhat is the best way to do server-side clustering? - server-sideC ++ Basic I / O Error - c ++Values ββin the trackbar - c #MouseOver / MouseOut EventListener inheriting child nodes? - javascriptAnimation of a 3D symbol in WPF - animationnull pointer exception when instantiating content? - javaThe point of using Injection Dependency (and in this case the IoC container) in LISP is springDownload FOLDER - javascriptRunning Python (from PHP) via MySQL - pythonAll Articles