Skip to content
XulbuX edited this page Nov 22, 2025 · 6 revisions

consts

This module contains constant values used throughout the library.


COLOR

This class provides hexadecimal color constants as strings.

Constant Color
WHITE
LIGHT_GRAY
GRAY
DARK_GRAY
BLACK
RED
CORAL
ORANGE
TANGERINE
GOLD
YELLOW
LIME
GREEN
NEON_GREEN
TEAL
CYAN
ICE
LIGHT_BLUE
BLUE
LAVENDER
PURPLE
MAGENTA
PINK
ROSE

CHARS

This class provides character set constants for text validation and filtering.

Constant Description
ALL Sentinel value indicating all characters are allowed.
DIGITS Numeric digits: 0-9
FLOAT_DIGITS Numeric digits with decimal point: 0-9 and .
HEX_DIGITS Hexadecimal digits: 0-9, a-f, A-F, and #
LOWERCASE Lowercase ASCII letters: a-z
LOWERCASE_EXTENDED Lowercase ASCII letters with diacritic marks
UPPERCASE Uppercase ASCII letters: A-Z
UPPERCASE_EXTENDED Uppercase ASCII letters with diacritic marks
LETTERS All ASCII letters: a-z and A-Z
LETTERS_EXTENDED All ASCII letters with diacritic marks
SPECIAL_ASCII Standard ASCII special characters and symbols
SPECIAL_ASCII_EXTENDED Standard and extended ASCII special characters
STANDARD_ASCII All standard ASCII characters (letters, digits, and symbols)
FULL_ASCII Complete ASCII character set including extended characters

ANSI

This class provides constants and utilities for working with ANSI escape code sequences.

Constant Description
ESCAPED_CHAR Printable ANSI escape character.
CHAR ANSI escape character.
START Start of an ANSI escape sequence.
SEP Separator between ANSI escape sequence parts.
END End of an ANSI escape sequence.

seq

Generates an ANSI escape sequence with the specified number of placeholders.
Param:placeholders: int = 1 number of placeholder parts in the sequence
Returns: formattable ANSI escape sequence string

SEQ_COLOR

ANSI escape sequence with three placeholders for setting the RGB text color. FormattableString

SEQ_BG_COLOR

ANSI escape sequence with three placeholders for setting the RGB background color. FormattableString


COLOR_MAP

Tuple containing the standard terminal color names:
tuple[str, ...]

CODES_MAP

Dictionary mapping format keys to their corresponding ANSI code numbers:
dict[str | tuple[str, ...], int]





exceptions

This module contains all custom exception classes used throughout the library.


SameContentFileExistsError

Raised when attempting to create a file that already exists with identical content.


PathNotFoundError

Raised when a file system path does not exist or cannot be accessed.





types

This module contains all custom type definitions used throughout the library.


Annotated Types

Int_0_100

Integer constrained to the range [0, 100] inclusive.

Int_0_255

Integer constrained to the range [0, 255] inclusive.

Int_0_360

Integer constrained to the range [0, 360] inclusive.

Float_0_1

Float constrained to the range [0.0, 1.0] inclusive.


FormattableString

String made to be formatted with the .format() method.


TypeAliases

Pattern

Matches compiled regex patterns from both the re and regex libraries.

Match

Matches regex match objects from both the re and regex libraries.


DataStructure

Union of supported data structures used in the data module.

IndexIterable

Union of all iterable types that support indexing operations.


Rgba

Matches all supported RGBA color value formats.

Hsla

Matches all supported HSLA color value formats.

Hexa

Matches all supported hexadecimal color value formats.


AnyRgba

Generic type alias for RGBA color values in any supported format (type checking disabled).

AnyHsla

Generic type alias for HSLA color values in any supported format (type checking disabled).

AnyHexa

Generic type alias for hexadecimal color values in any supported format (type checking disabled).


TypedDicts

ArgConfigWithDefault

Configuration schema for a flagged CLI argument that has a specified default value.

ArgResultRegular

Result schema for a parsed regular flagged CLI argument.

ArgResultPositional

Result schema for parsed positional ("before"/"after") CLI arguments.


MissingLibsMsgs

Configuration schema for custom messages in System.check_libs() when checking library dependencies.


Protocols

ProgressUpdater

Protocol for the progress updater function returned by ProgressBar.progress_context().

★⠀Python Library by XulbuX⠀★

Project Links

Testing and Formatting

Classifiers

  • Intended Audience:
    • Developers
  • License:
    • OSI Approved
    • MIT License
  • Operating Systems:
    • Full Library: OS Independent
  • Supported Python Versions:
    • Python 3.13
    • Python 3.12
    • Python 3.11
    • Python 3.10
  • Topics:
    • Libraries
    • Python Modules
    • Software Development

The XulbuX Logo

Clone this wiki locally