Skip to content

Commit 2f3809d

Browse files
committed
clarification
1 parent 0cbf728 commit 2f3809d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/how-to/render-and-compose.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ In this article we will clarify the differences, and use both these methods to b
1212
Render and compose are easy to confuse because they both ultimately define what a widget will look like, but they have quite different uses.
1313

1414
The `render` method on a widget returns a [Rich](https://rich.readthedocs.io/en/latest/) renderable, which is anything you could print with Rich.
15-
The simplest renderable is just text; so `render()` methods often return a string to display inside the widget, but could equally return a [`Text`](https://rich.readthedocs.io/en/latest/text.html) instance, a [`Table`](https://rich.readthedocs.io/en/latest/tables.html), or anything else from Rich (or third party library).
15+
The simplest renderable is just text; so `render()` methods often return a string, but could equally return a [`Text`](https://rich.readthedocs.io/en/latest/text.html) instance, a [`Table`](https://rich.readthedocs.io/en/latest/tables.html), or anything else from Rich (or third party library).
16+
Whatever is returned from `render()` will be combined with any styles from CSS and displayed within the widget's borders.
1617

1718
The `compose` method is used to build [*compound* widgets](../guide/widgets.md#compound-widgets) (widgets composed of other widgets).
1819

0 commit comments

Comments
 (0)