MCPcopy
hub / github.com/Textualize/rich / __init__

Method __init__

rich/markdown.py:468–483  ·  view source on GitHub ↗
(
        self,
        console: Console,
        options: ConsoleOptions,
        style: Style,
        inline_code_lexer: str | None = None,
        inline_code_theme: str = "monokai",
    )

Source from the content-addressed store, hash-verified

466 """Manages the console render state."""
467
468 def __init__(
469 self,
470 console: Console,
471 options: ConsoleOptions,
472 style: Style,
473 inline_code_lexer: str | None = None,
474 inline_code_theme: str = "monokai",
475 ) -> None:
476 self.console = console
477 self.options = options
478 self.style_stack: StyleStack = StyleStack(style)
479 self.stack: Stack[MarkdownElement] = Stack()
480
481 self._syntax: Syntax | None = None
482 if inline_code_lexer is not None:
483 self._syntax = Syntax("", inline_code_lexer, theme=inline_code_theme)
484
485 @property
486 def current_style(self) -> Style:

Callers

nothing calls this directly

Calls 3

StyleStackClass · 0.85
SyntaxClass · 0.85
StackClass · 0.70

Tested by

no test coverage detected