mirror of
https://github.com/Textualize/rich.git
synced 2025-08-04 01:58:24 +00:00
docs
This commit is contained in:
parent
e75649a870
commit
f484e4707f
2 changed files with 8 additions and 1 deletions
|
@ -69,6 +69,11 @@ This allows you to specify the text of the column only. If you want to set other
|
|||
title="Star Wars Movies"
|
||||
)
|
||||
|
||||
Lines
|
||||
~~~~~
|
||||
|
||||
By default, Tables will show a line under the header only. If you want to show lines between all rows add ``show_lines=True`` to the constructor.
|
||||
|
||||
Grids
|
||||
~~~~~
|
||||
|
||||
|
|
|
@ -3,7 +3,9 @@
|
|||
Rich Text
|
||||
=========
|
||||
|
||||
Rich has a :class:`~rich.text.Text` class you can use to mark up strings with color and style attributes. You can consider this class to be like a mutable string which also contains style information.
|
||||
Rich has a :class:`~rich.text.Text` class you can use to mark up strings with color and style attributes. You can use a Text instance anywhere a string is accepted, which gives you a lot of control over presentation.
|
||||
|
||||
You can consider this class to be like a string with marked up regions of text. Unlike a builtin ``str``, a Text instance is mutable, and most methods operate in-place rather than returning a new instance.
|
||||
|
||||
One way to add a style to Text is the :meth:`~rich.text.Text.stylize` method which applies a style to a start and end offset. Here is an example::
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue