-
Hello, I want the text to appear above the progress bar. Thank you in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Hi, By default the progress bar in rich will be shown under the text being printed. Here is a very simple code sample that will do what you want: import time
from rich.progress import track
sample_text = [
"Text may be printed while the progress bars are rendering.",
"This is pretty neat.",
"I do not have a lot of things to say.",
"So I will stop here."
]
for example in track(sample_text, total=len(sample_text)):
time.sleep(1)
print(example) rich also has a more advance example you can run: python -m rich.progress This is a more feature rich solution that you can look at here (😜pun intended). Here is the quick rundown:
I am pretty sure you can skip line 1012 and not give a value to the Hope this helps. |
Beta Was this translation helpful? Give feedback.
Hi,
By default the progress bar in rich will be shown under the text being printed.
Here is a very simple code sample that will do what you want:
rich also has a more advance example you can run:
This is a more feature rich solution that you can look at here (😜pun intended).
Here is the quick rundown: