MCPcopy Index your code
hub / github.com/ipython/ipython / __init__

Method __init__

IPython/utils/PyColorize.py:45–58  ·  view source on GitHub ↗
(
        self,
        name: str,
        base: str | None,
        extra_style: dict[_TokenType, str],
        *,
        symbols: Symbols | None = None,
    )

Source from the content-addressed store, hash-verified

43 symbols: Symbols
44
45 def __init__(
46 self,
47 name: str,
48 base: str | None,
49 extra_style: dict[_TokenType, str],
50 *,
51 symbols: Symbols | None = None,
52 ) -> None:
53 self.name = name
54 self.base = base
55 self.extra_style = extra_style
56 s: Symbols = symbols if symbols is not None else _default_symbols
57 self.symbols = {**_default_symbols, **s}
58 self._formatter = Terminal256Formatter(style=self.as_pygments_style())
59
60 @cache
61 def as_pygments_style(self) -> Type[Style]:

Callers

nothing calls this directly

Calls 1

as_pygments_styleMethod · 0.95

Tested by

no test coverage detected