This commit is contained in:
Will McGugan 2020-06-12 10:26:11 +01:00
parent c24ab497ea
commit 7147c60886
1 changed files with 2 additions and 2 deletions

View File

@ -47,9 +47,9 @@ Here's a simple example::
Transient progress Transient progress
~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~
Normally when you exit the progress context manager (or call :meth:`~rich.progress.Progress.stop`) the last refreshed display remains in the terminal with the cursor on the following line. You can also make the progress display disappear on exit by setting ``transient=False`` on the Progress constructor. Here's an example Normally when you exit the progress context manager (or call :meth:`~rich.progress.Progress.stop`) the last refreshed display remains in the terminal with the cursor on the following line. You can also make the progress display disappear on exit by setting ``transient=True`` on the Progress constructor. Here's an example::
with Progress(transient=False) as progress: with Progress(transient=True) as progress:
task = progress.add_task("Working", total=100) task = progress.add_task("Working", total=100)
do_work(task) do_work(task)