mirror of
https://github.com/1j01/textual-paint.git
synced 2024-12-21 05:41:54 +03:00
43 lines
934 B
Python
43 lines
934 B
Python
"""
|
|
This type stub file was generated by pyright.
|
|
"""
|
|
|
|
from dataclasses import dataclass
|
|
from enum import Enum
|
|
from .instruction import Instruction
|
|
|
|
"""ANSI text style attributes."""
|
|
class Attribute(Enum):
|
|
"""An ANSI text style attribute."""
|
|
NORMAL = ...
|
|
BOLD = ...
|
|
DIM = ...
|
|
NEITHER_BOLD_NOR_DIM = ...
|
|
ITALIC = ...
|
|
NOT_ITALIC = ...
|
|
UNDERLINE = ...
|
|
NOT_UNDERLINE = ...
|
|
BLINK = ...
|
|
NOT_BLINK = ...
|
|
REVERSE = ...
|
|
NOT_REVERSE = ...
|
|
HIDDEN = ...
|
|
NOT_HIDDEN = ...
|
|
def is_on(self): # -> bool:
|
|
"""Return True if this attribute actually "turns on" an attribute."""
|
|
...
|
|
|
|
def is_off(self): # -> Any:
|
|
"""Return True if this attribute actually "turns off" (resets) an attribute."""
|
|
...
|
|
|
|
|
|
|
|
@dataclass
|
|
class SetAttribute(Instruction[Attribute]):
|
|
"""Instruction to set an ANSI text style attribute."""
|
|
attribute: Attribute
|
|
...
|
|
|
|
|