awesomeWM / awesome

awesome window manager
https://awesomewm.org/
GNU General Public License v2.0
6.39k stars 597 forks source link

wibox.widget.systray doesn't support pseudo-transparency #363

Open flyboy14 opened 9 years ago

flyboy14 commented 9 years ago

Hello! I found out that there is built-in pseudo-transparency for wiboxes in awesome 3.1 and newer. It can be enabled by appending 2 hexadecimal digits to the colors in theme file:

theme.bg_normal = #000000AA --"AA" is the transparency value. 

It works good for wiboxes and all widgets, but but unortunately it does'nt work for wibox.widget.systray(). For example, this: (in theme.lua)

theme.bg_systray = "#121212AA"

works exactly like this:

theme.bg_systray = "#121212"

I wonder if there's a way to make systray transparent due to match my system theme. Screenshots included. screenshot-20150728-154406 screenshot-20150728-154409 Thanks!

blueyed commented 9 years ago

Might be related to https://github.com/awesomeWM/awesome/issues/359.

flyboy14 commented 9 years ago

No. It's not about redrawing. When I restart awesome with value #ffffff systray becomes white and with value #121212 it becomes dark grey. But pseudo-transparency that works with awful.menu and awful.wibox doesn't seem to work with systray widget

psychon commented 9 years ago

Same issue in old tracker: https://awesome.naquadah.org/bugs/index.php?do=details&task_id=513

timroes commented 9 years ago

Reading through the ticket history also in the old issue tracker, I am not sure if my systray issue is related to that. Even without any transparency background colors and drawing is pretty broken (but still looks like it could be related):

screenshot-20150921-191509

I actually set the background color of the systray to #FF00FF. Only the volume icon seem to work well. The synology cloud station icon will always draw on black background. The dropbox icon (as can be seen in the picture) draws over a copy of one of the other icons.

Since this behavior seem to stick to the icons whenever they appear it might also be an issue in dropbox/synologies software. Has anyone similar issues with their systray.

Also, is the issue with the pseudo transparency something, that is planned to be fixed?

psychon commented 9 years ago

@timroes That might very well be a Qt bug and the "draws over a copy of one of the other icons" might be one of my attempts at fixing this bug in Qt.

And for fixing pseudo transparency with the systray: If you tell me how, I could look into that. So far I haven't seen/had any sane ideas.

Determinant commented 6 years ago

I'm also experiencing the same problem. Any update on this bug?

psychon commented 6 years ago

@Determinant No

ervasive commented 6 years ago

And for fixing pseudo transparency with the systray: If you tell me how, I could look into that. So far I haven't seen/had any sane ideas.

I have zero clues of how systray is implemented or what can be done regarding this issue but tint2 handles tray icons pretty well in my experience, maybe some ideas could be gathered from there. Just my 5 cents.

Also, currently there is not much info about this limitation in the docs besides the following:

The color (string like “#ff0000” only) 

Maybe it could be stated more explicitly there as well.

Elv13 commented 6 years ago

but tint2 handles tray icons pretty well in my experience,

The issue has never been that it's impossible to implement. The issue is that the protocol wasn't designed for that in mind and the complexity associated with making it work is not worth it from a maintainer point of view. KDE (both v4 and v5) at first refused to implement it but eventually gave up that stance due to user pressure (and regret it). Gnome (3) also refused to do the necessary hacks (at least by default).

ervasive commented 6 years ago

Oh, I wasn't aware of that. If I understand correctly the issue is related to XEMBED based system tray specification and occurs all over the place: https://github.com/Airblader/i3/issues/90 https://github.com/jaagr/polybar/issues/854 https://github.com/travitch/taffybar/issues/177

Here is some explanation: https://github.com/Airblader/i3/issues/90#issuecomment-225802441 https://github.com/Airblader/i3/issues/90#issuecomment-225995287

actionless commented 6 years ago

my workaround is to have tray which is hiding on click/hotkey

for sure won't work for anyone who really need to observe some status info from tray all the time

nemya9066 commented 4 years ago

Same problem systray transparency work fine on polybar btw can anyone refer me to where the problem is in the code?

psychon commented 4 years ago

@nemya9066 https://github.com/awesomeWM/awesome/issues/363#issuecomment-379061733

nemya9066 commented 3 years ago

@nemya9066 #363 (comment)

The thing is this issue doesn't seem to exist in polybar so clearly there is some sort of fix to this bug that can be implemented.

NatanielRegula commented 2 years ago

The same issue still exist. Is there any update on the matter?

Aire-One commented 2 years ago

We have https://github.com/awesomeWM/awesome/pull/3664 that needs some attention.

linuxmobile commented 1 year ago

Continue this without fix? How to solve please.

Elv13 commented 1 year ago

https://github.com/awesomeWM/awesome/pull/3664 fixes it. But I don't have enough time right now and it's stuck in my review queue.