Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes15kdownloads
wcwidth.py70 linesDownload Raw Back to wcwidth
1"""2Legacy compatibility module for wcwidth.wcwidth.3 4This file contains no new definitions and is provided only for backwards5compatibility.  This module exists solely to support legacy import paths::6 7    from wcwidth.wcwidth import iter_graphemes8    from wcwidth.wcwidth import _SGR_PATTERN9    import wcwidth.wcwidth as legacy10"""11# pylint: disable=unused-import12 13# local14from ._clip import clip15from .align import ljust, rjust, center16from ._width import _CONTROL_CHAR_TABLE, _WIDTH_FAST_PATH_MIN_LEN, width, _width_ignored_codes17from ._wcwidth import wcwidth, _wcmatch_version, _wcversion_value18from .bisearch import bisearch as _bisearch19from .grapheme import iter_graphemes20from .table_mc import CATEGORY_MC21from ._wcswidth import wcswidth22from .sgr_state import (_SGR_PATTERN,23                        _SGR_STATE_DEFAULT,24                        _sgr_state_update,25                        _sgr_state_is_active,26                        _sgr_state_to_sequence)27from ._constants import (_EMOJI_ZWJ_SET,28                         _ISC_VIRAMA_SET,29                         _LATEST_VERSION,30                         _AMBIGUOUS_TABLE,31                         _ZERO_WIDTH_TABLE,32                         _CATEGORY_MC_TABLE,33                         _FITZPATRICK_RANGE,34                         _WIDE_EASTASIAN_TABLE,35                         _REGIONAL_INDICATOR_SET)36from .table_vs16 import VS16_NARROW_TO_WIDE37from .table_wide import WIDE_EASTASIAN38from .table_zero import ZERO_WIDTH39from .control_codes import ILLEGAL_CTRL, VERTICAL_CTRL, HORIZONTAL_CTRL, ZERO_WIDTH_CTRL40from .table_grapheme import ISC_CONSONANT, EXTENDED_PICTOGRAPHIC, GRAPHEME_REGIONAL_INDICATOR41from .table_ambiguous import AMBIGUOUS_EASTASIAN42from .escape_sequences import (ZERO_WIDTH_PATTERN,43                               CURSOR_LEFT_SEQUENCE,44                               CURSOR_RIGHT_SEQUENCE,45                               INDETERMINATE_EFFECT_SEQUENCE,46                               iter_sequences,47                               strip_sequences)48from .unicode_versions import list_versions49 50_ISC_CONSONANT_TABLE = ISC_CONSONANT51 52__all__ = (53    'ZERO_WIDTH',54    'WIDE_EASTASIAN',55    'AMBIGUOUS_EASTASIAN',56    'VS16_NARROW_TO_WIDE',57    'list_versions',58    'wcwidth',59    'wcswidth',60    'width',61    'iter_sequences',62    'ljust',63    'rjust',64    'center',65    'clip',66    'strip_sequences',67    '_wcmatch_version',68    '_wcversion_value',69)70 
codekingpro/portable-devtools · Team Ai