Skip to main content

Detect whether the terminal supports advanced Unicode.

Project description

> is-unicode-supported

Detect whether the terminal supports advanced Unicode.

Checks if terminal supports advanced Unicode (CJK, emoji, etc.) by measuring the cursor position of a single, wide char (𠀀). Returns False for legacy consoles or True if the wide char renders as 2 columns.

⚡ Installation

pip install is-unicode-supported

💻 Command line usage

is-unicode-supported  # or supportsunicode
# e.g. => True

CLI options:

Option Description
-h, --help Show help screen
-v, --version Show version
--docs Open docs URL

🔌 API usage

import is_unicode_supported

if is_unicode_supported():
    print('Advanced Unicode supported!')
else:
    print('Advanced Unicode not supported!')

Note: Most type checkers will falsely warn is_unicode_supported is not a callable module because they are incapable of analyzing runtime behavior (where the module is replaced w/ a function for cleaner, direct access). You can safely suppress such warnings using # type: ignore.

MIT License

Copyright © 2026 Adam Lui

Related

🇪🇸 latin-locales - ISO 639-1 (2-letter) codes for Latin locales.
🇨🇳 non-latin-locales - ISO 639-1 (2-letter) codes for non-Latin locales.
🌍 translate-messages - Translate en/messages.json (chrome.i18n format) to 100+ locales automatically.

More Python utilities / Back to top ↑

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

is_unicode_supported-1.2.0.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

is_unicode_supported-1.2.0-py3-none-any.whl (19.2 kB view details)

Uploaded Python 3

File details

Details for the file is_unicode_supported-1.2.0.tar.gz.

File metadata

  • Download URL: is_unicode_supported-1.2.0.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.2

File hashes

Hashes for is_unicode_supported-1.2.0.tar.gz
Algorithm Hash digest
SHA256 13b13b2a859300ef042571456481709d26025922392b6fdaed2bf33d5b806abf
MD5 c1a8430ebe9299704d806bdfb63210f9
BLAKE2b-256 f6c6f46117aa411b843361cbb365ef855154aa18f79fde0ad97ba8d4b3b8b7a4

See more details on using hashes here.

File details

Details for the file is_unicode_supported-1.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for is_unicode_supported-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b8996973b0dde7366ccd5f8ba3c24213bfc8755ee9e5e5d8abf0a3722f43ec71
MD5 3fdba43c34aae2c15936ab25d6dc5b70
BLAKE2b-256 cc36738ffbdff49d349c8ba1c3ba1523d890b08974749480a88c695aea299c65

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page