# `GSGlyph.unicode`

*Instance Property*

The first Unicode code point associated with the glyph, as an uppercase hexadecimal string.

## Declaration

```swift
var unicode: String? { get set }
```

```objc
@property (nonatomic, copy) NSString * unicode;
```

[See also `unicode` in the Python API](https://docu.glyphsapp.com/#GSGlyph.unicode)

```python
pyobjc_instanceMethods.unicode() -> str
pyobjc_instanceMethods.setUnicode_(unicode: str)
```

## Discussion

Assigning this property replaces all existing Unicode code points. A value of `nil` leaves the glyph without an associated Unicode code point.

## See Also

### Unicode and Characters

- [`GSGlyph.unicodes`](/Core/GlyphsCore/GSGlyph/unicodes) — The Unicode code points associated with the glyph, as an ordered set of uppercase hexadecimal strings.
- [`GSGlyph countOfUnicodes`](/Core/GlyphsCore/GSGlyph/countOfUnicodes) — The number of associated Unicode code points.
- [`GSGlyph.unicodeChar`](/Core/GlyphsCore/GSGlyph/unicodeChar) — The numeric value of the first associated Unicode code point, or `0` when there is none.
- [`GSGlyph charString`](/Core/GlyphsCore/GSGlyph/charString) — The character for the first associated Unicode code point, or an empty string when this convenience API cannot represent it.
- [`GSGlyph addUnicode:`](/Core/GlyphsCore/GSGlyph/addUnicode:) — Adds a Unicode code point while preserving the existing code points.
- [`GSGlyph removeUnicode:`](/Core/GlyphsCore/GSGlyph/removeUnicode:) — Removes a Unicode code point while preserving the order of the remaining code points.
- [`GSGlyph setUnicodesFast:`](/Core/GlyphsCore/GSGlyph/setUnicodesFast:) — Assigns Unicode code points without updating related state.
- [`GSGlyph isValidUnicodeString:error:`](/Core/GlyphsCore/GSGlyph/isValidUnicodeString:error:) — Checks whether a string uses the uppercase hexadecimal syntax for a Unicode code point.
- [`GSGlyph.baseString`](/Core/GlyphsCore/GSGlyph/baseString) — The Unicode string represented by the glyph’s character composition.

