Skip to content

color ¤

Modules:

Classes:

Functions:

Attributes:

NORMAL module-attribute ¤

NORMAL = '\x1b[0m'

BLACK module-attribute ¤

BLACK = '\x1b[30m'

RED module-attribute ¤

RED = '\x1b[31m'

GREEN module-attribute ¤

GREEN = '\x1b[32m'

YELLOW module-attribute ¤

YELLOW = '\x1b[33m'

BLUE module-attribute ¤

BLUE = '\x1b[34m'

PURPLE module-attribute ¤

PURPLE = '\x1b[35m'

CYAN module-attribute ¤

CYAN = '\x1b[36m'

LIGHT_GREY module-attribute ¤

LIGHT_GREY = '\x1b[37m'

LIGHT_GRAY module-attribute ¤

LIGHT_GRAY = '\x1b[37m'

FOREGROUND module-attribute ¤

FOREGROUND = '\x1b[39m'

GREY module-attribute ¤

GREY = '\x1b[90m'

GRAY module-attribute ¤

GRAY = '\x1b[90m'

LIGHT_RED module-attribute ¤

LIGHT_RED = '\x1b[91m'

LIGHT_GREEN module-attribute ¤

LIGHT_GREEN = '\x1b[92m'

LIGHT_YELLOW module-attribute ¤

LIGHT_YELLOW = '\x1b[93m'

LIGHT_BLUE module-attribute ¤

LIGHT_BLUE = '\x1b[94m'

LIGHT_PURPLE module-attribute ¤

LIGHT_PURPLE = '\x1b[95m'

LIGHT_CYAN module-attribute ¤

LIGHT_CYAN = '\x1b[96m'

WHITE module-attribute ¤

WHITE = '\x1b[97m'

BOLD module-attribute ¤

BOLD = '\x1b[1m'

UNDERLINE module-attribute ¤

UNDERLINE = '\x1b[4m'

none module-attribute ¤

none = str

ansi_escape_8bit module-attribute ¤

ansi_escape_8bit = compile(
    "(?:\\x1B[@-Z\\\\-_]|[\\x80-\\x9A\\x9C-\\x9F]|(?:\\x1B\\[|\\x9B)[0-?]*[ -/]*[@-~])"
)

disable_colors module-attribute ¤

disable_colors = add_param(
    "disable-colors",
    bool(get("PWNDBG_DISABLE_COLORS")),
    "whether to color the output or not",
)

ColorParamSpec ¤

Bases: NamedTuple

Attributes:

name instance-attribute ¤

name: str

default instance-attribute ¤

default: str

doc instance-attribute ¤

doc: str

ColorConfig ¤

ColorConfig(namespace: str, params: list[ColorParamSpec])

Methods:

__getattr__ ¤

__getattr__(attr: str) -> Callable[[str], str]

normal ¤

normal(x: str) -> str

black ¤

black(x: str) -> str

red ¤

red(x: str) -> str

green ¤

green(x: str) -> str

yellow ¤

yellow(x: str) -> str

blue ¤

blue(x: str) -> str

purple ¤

purple(x: str) -> str

cyan ¤

cyan(x: str) -> str

light_gray ¤

light_gray(x: str) -> str

foreground ¤

foreground(x: str) -> str

gray ¤

gray(x: str) -> str

light_red ¤

light_red(x: str) -> str

light_green ¤

light_green(x: str) -> str

light_yellow ¤

light_yellow(x: str) -> str

light_blue ¤

light_blue(x: str) -> str

light_purple ¤

light_purple(x: str) -> str

light_cyan ¤

light_cyan(x: str) -> str

white ¤

white(x: str) -> str

bold ¤

bold(x: str) -> str

underline ¤

underline(x: str) -> str

colorize ¤

colorize(x: str, color: str) -> str

unstylize ¤

unstylize(x: str) -> str

generateColorFunctionInner ¤

generateColorFunctionInner(
    old: Callable[[object], str], new: Callable[[str], str]
) -> Callable[[object], str]

generateColorFunction ¤

generateColorFunction(
    config: str | Parameter,
    _globals: dict[str, Callable[[str], str]] = globals(),
) -> Callable[[object], str]

strip ¤

strip(x: str) -> str

terminateWith ¤

terminateWith(x: str, color: str) -> str

ljust_colored ¤

ljust_colored(x: str, length: int, char: str = ' ') -> str

rjust_colored ¤

rjust_colored(x: str, length: int, char: str = ' ')