I just couldn't find utf-8 encoding for character like following:
I think that it is quite possible to create this in code, as a composed character from two dashes: /
and \
, but I do not know what characters to compose.
I just couldn't find utf-8 encoding for character like following:
I think that it is quite possible to create this in code, as a composed character from two dashes: /
and \
, but I do not know what characters to compose.
Possibly U+2039.
print("\u{2039}") // ‹
Or U+276E.
print("\u{276E}") // ❮
I'm not certain if this will work for a navigation item, but you could make use of NSAttributedString
to have string with different sizes of the substrings within it. This is described in detail in this great answer:
As an example for your case:
let myAttributeBack = [ NSFontAttributeName: UIFont(name: "HelveticaNeue-UltraLight", size: 30.0)!]
let attrString = NSMutableAttributedString(string: "\u{276E} ", attributes: myAttributeBack)
let myAttributeText = [ NSFontAttributeName: UIFont(name: "HelveticaNeue-UltraLight", size: 15.0)!]
let backString = NSAttributedString(string: "back", attributes: myAttributeText)
attrString.appendAttributedString(backString)
myLabel.attributedText = attrString
However, as you write below, perhaps it's not possible to use attributed strings for title of a navigation bar item. Then I'd assume that the navigation bar example you showed above simply contains an image with the back bracket and a string "back" for the title text.