lxqt / lxqt-panel

The LXQt desktop panel
https://lxqt-project.org
GNU Lesser General Public License v2.1
179 stars 135 forks source link

enable using color in panel custom widgets #2032

Closed hmbns closed 4 months ago

hmbns commented 4 months ago

Is your feature request related to a problem? Please describe.

I can't use color defined in bash script when i use it as a widget.

Describe the solution you'd like

I would love to be able to use color configured in bash script to appear on widget just like with echo -e in terminal.

now when my echo output contains a defined coloring it's treated as text Describe eventual alternatives you've considered

Context

i was looking in panel settings and config files but i can't find an option to somehow change it. only option that i found is to change font color of the entire panel but thats not what i'm looking for.

tsujan commented 4 months ago

The text color you see in a terminal is as related to Custom Command as is the background of your terminal: there can simply be no relation. The foreground and background colors are determined by the panel style. Custom Command is a button with a text.

gfgit commented 4 months ago

If I understand correctly, you would like to change Custom Command button's color. Have you looked at lxqt-themes? There are .qss files in which you can set style for various parts of the panels and other LXQt components. See Qt Docs for syntax :)

hmbns commented 4 months ago

If I understand correctly, you would like to change Custom Command button's color. Have you looked at lxqt-themes? There are .qss files in which you can set style for various parts of the panels and other LXQt components. See Qt Docs for syntax :)

thanks : ) or maybe there is some tool that would allow me to display straight output from terminal, similar to i3 panel?

gfgit commented 4 months ago

I've never tried i3 but if you put %1 inside custom command button's text it will get replaced by command output.

Example: Button text: I'm %1 Command: echo Happy