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

Method renderable

rich/live.py:215–228  ·  view source on GitHub ↗

Get the renderable that is being displayed Returns: RenderableType: Displayed renderable.

(self)

Source from the content-addressed store, hash-verified

213
214 @property
215 def renderable(self) -> RenderableType:
216 """Get the renderable that is being displayed
217
218 Returns:
219 RenderableType: Displayed renderable.
220 """
221 live_stack = self.console._live_stack
222 renderable: RenderableType
223 if live_stack and self is live_stack[0]:
224 # The first Live instance will render everything in the Live stack
225 renderable = Group(*[live.get_renderable() for live in live_stack])
226 else:
227 renderable = self.get_renderable()
228 return Screen(renderable) if self._alt_screen else renderable
229
230 def update(self, renderable: RenderableType, *, refresh: bool = False) -> None:
231 """Update the renderable that is being displayed

Callers

nothing calls this directly

Calls 3

get_renderableMethod · 0.95
GroupClass · 0.85
ScreenClass · 0.85

Tested by

no test coverage detected