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

Method __rich_console__

rich/styled.py:23–29  ·  view source on GitHub ↗
(
        self, console: "Console", options: "ConsoleOptions"
    )

Source from the content-addressed store, hash-verified

21 self.style = style
22
23 def __rich_console__(
24 self, console: "Console", options: "ConsoleOptions"
25 ) -> "RenderResult":
26 style = console.get_style(self.style)
27 rendered_segments = console.render(self.renderable, options)
28 segments = Segment.apply_style(rendered_segments, style)
29 return segments
30
31 def __rich_measure__(
32 self, console: "Console", options: "ConsoleOptions"

Callers

nothing calls this directly

Calls 3

get_styleMethod · 0.80
apply_styleMethod · 0.80
renderMethod · 0.45

Tested by

no test coverage detected