unicodedata

The unicodedata module provides access to the Unicode character database, which contains character properties for all Unicode characters.

bidirectional(unichr)

Returns the bidirectional category assigned to unichr as a string, or an empty string if no such value is defined. Returns one of the following:

ValueDescription
LLeft-to-Right
LRELeft-to-Right Embedding
LROLeft-to-Right Override
RRight-to-Left
ALRight-to-Left Arabic
RLERight-to-Left Embedding
RLORight-to-Left Override
PDFPop Directional Format
ENEuropean Number
ESEuropean Number Separator
ETEuropean Number Terminator
ANArabic Number
CSCommon Number Separator
NSMNon-Spacing Mark
BNBoundary Neutral
BParagraph Separator
SSegment Separator
WSWhitespace
ONOther Neutrals
category(unichr)

Returns a ...

Get Python: Essential Reference, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.