Does any one know how to display the copyright icon in UILabel text? This is the icon with a circle around c. The html code for it is: ©
or ©
.
I tried the following code:
UILabel *contactInfo = [[UILabel alloc] initWithFrame:CGRectMake(-55,135,420,100)];
contactInfo.text = @"'©):'2009 Nationwide ";
or
contactInfo.text = @"'©'2009 Nationwide ";
or
contactInfo.text = @"©2009 Nationwide ";
It just prints everything as text and no icon.
This would work in a webView but I need it as UILabel text. Any help?
From there you can drag a UIImageView and UILabel into the view you just created. Set the image of the UIImageView in the properties inspector as the custom bullet image (which you will have to add to your project by dragging it into the navigation pane) and you can write some text in the label.
To change the font or the size of a UILabel in a Storyboard or . XIB file, open it in the interface builder. Select the label and then open up the Attribute Inspector (CMD + Option + 5). Select the button on the font box and then you can change your text size or font.
A view that displays one or more lines of informational text.
If your source files are in UTF-8, what they should be, this should work just fine. Otherwise you should use .strings-files in combination with the NSLocalizedString() macro and put your text into UTF-16 files.
Works for me: myUILabel.text = @"© by me";
(source: hillrippers.ch)
Edit: Now that I see that you've tried to insert the symbol as HTML entity - this does not work, just insert the symbol as it appears.
In interface builder try Option and G together.
If you don't have an Option key, try with ALT.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With