On this page
unicodedata.lookup
Prev: unicodedata.is_normalized | Up: unicodedata | Next: unicodedata.mirrored
Rel: unicodedata.bidirectional, unicodedata.category, unicodedata.combining, unicodedata.decimal
Ref: docs.python.org — unicodedata.lookup
Tags: #public #python3 #stdlib #unicodedata
Import
import unicodedata
from unicodedata import lookup
Signature & Overview
unicodedata.lookup(name, /)
Look up character by name.
Usage
import unicodedata
assert unicodedata.lookup('GREEK SMALL LETTER PI') == 'π'
Gotchas
- Raises
KeyErroron unknown names (same names used in\N{...}string escapes).
REPL Inspect
from unicodedata import lookup
help(lookup)
Linked from
Related notes
- tuts/python3/stdlib_module/unicodedata/is_normalized Linked here; links to this page; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/mirrored Linked here; links to this page; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata Linked here; links to this page; shared tags: #stdlib
- tuts/python3/stdlib_module/unicodedata/bidirectional Linked here; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/category Linked here; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/combining Linked here; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/decimal Linked here; shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/decomposition shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/digit shared tags: #stdlib, #unicodedata
- tuts/python3/stdlib_module/unicodedata/east_asian_width shared tags: #stdlib, #unicodedata