Questions tagged [rich]

Rich is a Python library for rich text and beautiful formatting in the terminal.

99 questions
0
votes
0 answers

Module rich and wget python

Can wget and rich communicate with each other? And if so, how? import time from rich.progress import track import wget url_1 = "https://server/model.txt" for i in track(range(20), description="Processing..."): wget.download(url_1) At When I…
Mr. Magic
  • 3
  • 1
0
votes
0 answers

What makes Rich display wrong characters on Powershell 7?

I've been a happy user of Rich for Python for some time now, but recently started having issues where colors and special characters are not displayed properly anymore. Here is an example output of printing a Table in Powershell 7…
Thrastylon
  • 853
  • 7
  • 20
0
votes
0 answers

How do I render a table in a specific Layout() using the python rich Live() class

Here is the code to create the layout import time from rich.live import Live from rich.table import Table from rich.layout import Layout layout=Layout() layout.split_row( Layout(name="left"), Layout(name="right"), ) print(layout) I would like…
MiniMe
  • 1,057
  • 4
  • 22
  • 47
0
votes
1 answer

Using APscheduler with Textual in Python

i need a scheduler in a Textual application to periodically query an external data source. As a test i've tried to use APscheduler to call a tick() function every second. However nothing happens although the scheduler should be started. What is…
Marvin Noll
  • 585
  • 1
  • 7
  • 23
0
votes
0 answers

Use rich module in curses panel

It's my first time with curses module and I want make menu with this. I have found example on internet for make this. import curses from curses import panel class Menu(object): def __init__(self, items, stdscreen): self.window =…
0
votes
0 answers

How to use a variable value instead of variable's name in Python

Sorry if the title sounds weird im new here here's my problem def populate(self, att, obj): ans = [] for item in att: item = item.replace(obj.__class__.__name__, "") ans.append(item) for mem in ans: …
Siddharth
  • 1
  • 1
0
votes
0 answers

Multiprocessing or multithreading for my Rich UI in python

Okay so I'm writing a commandline program in python using the Rich library for my UI basically. Now I've written a method that changes the color of the program logo (Text) every second to create a simple RGB animation. Now when I run the animation…
0
votes
0 answers

Is there a way to include download progress bars from rich while logging from youtube-dl?

I'm making a script that mass downloads youtube videos from a text file, and wanted to spice up the console logging a bit with rich. However, while the system that I have does output using rich, it doesn't have progress bars for the download. This…
0
votes
0 answers

Rich Table printed in a loop multiple times, why?

I have found this code on the internet and modified it with RICH table-output: I have removed all the code that is not neccessary to understand (all the imports and so on). My PROBLEM is, that the Table repeats itself. But there is NO loop for…
user20630484
0
votes
0 answers

How python rich library print?

I'm new in python and I use the rich python library to color and format my console. I don't have level to understnad the library alone , but i want to understand how it work to print colored pixel and format text in a console ? Do it draw pixel…
0
votes
1 answer

Call layout within a layout using RICH PYTHON , when user give a keyboard input

I have a layout( live display), which showing some database information, . My requirement is If user provides an input from keyboard on layout one, then a new layout will be called, which holds different set of rich renderables. I didnt find any…
0
votes
2 answers

Pre-existing high-contrast palettes from the ANSI color set, to use in a terminal app?

Looking to convey more information in a Rich Table by using colors (specifically to track which modules given classes come from). On the web, it's fairly easy on find color palettes that are optimized for contrast, rather than esthetics. Here's a 6…
JL Peyret
  • 10,917
  • 2
  • 54
  • 73
0
votes
1 answer

How can I put a table inside a layout box using Rich in Python?

This is code I am using to put a table inside the layout. However, in the output I am getting lot of ansii code-like characters, and even though I have defined the colour attribute for the column, in the output it is not appearing. from re import…
0
votes
0 answers

Texting in RichEditor with big html laggng

I have RichEditor field and it loading html. rischEditText = composeView.findViewById(R.id.compose); rischEditText.loadCSS("file:///android_asset/style.css"); When user have very big html, and then user start texting in RichEditor, text writing in…
Slava
  • 443
  • 4
  • 12
0
votes
1 answer

How to print variables with rich console

I want to print the series variable in bold and color it red after the user input is provided. This is the code I am currently using... series = console.input("Search [bold cyan]Series[/] :earth_asia:\n> ") console.print('Searching for [bold red]…