telegramdesktop / tdesktop

Telegram Desktop messaging app
https://desktop.telegram.org/
Other
26.33k stars 5.23k forks source link

Tray icon is dark instead of white #10556

Closed ghost closed 3 years ago

ghost commented 3 years ago

Steps to reproduce

  1. Launch telegram

Expected behaviour

Telegram tray icon should be white

Actual behaviour

Telegram tray icon is dark

Configuration

Operating system: Arch Linux x86_64 Window Manager: bspwm with polybar

Version of Telegram Desktop: 2.6.1

Installation source (Linux Only) - the official website / GitHub releases / flatpak / snap / distribution package: Arch community package https://archlinux.org/packages/community/x86_64/telegram-desktop/

Used theme: According to neofetch: Theme: Orchis-dark [GTK2/3] Icons: Qogir-dark [GTK2/3]

Screenshot

image

I tried changing the icon theme and it's still dark. I haven't really changed anything significant from what I remember.

ilya-fedin commented 3 years ago

Probably you have set another icon theme for Qt applications? Check QT_QPA_PLATFORMTHEME variable.

ghost commented 3 years ago

Mine is set to 'gnome'. What I don't understand is why this would be causing an issue now. I haven't really changed anything regarding the theme in a while and it was fine before. Just kinda happened randomly. I'll experiment with the theme stuff later and report back.

Aokromes commented 3 years ago

i suggest you to download official package from desktop.telegram.org or from releases, from what i was told archlinux stoped to maintain distribution package.

ilya-fedin commented 3 years ago

i suggest you to download official package from desktop.telegram.org or from releases, from what i was told archlinux stoped to maintain distribution package.

No, it's fedora&gentoo.

ilya-fedin commented 3 years ago

Mine is set to 'gnome'.

Do you have QGnomePlatform installed? Do you have any tdesktop-related environments variables (env | grep -e TDESKTOP -e DESKTOP_APP) set?

ghost commented 3 years ago

I have QGnomePlatform installed and no outputs on my console for env | grep -e TDESKTOP -e DESKTOP_APP

ilya-fedin commented 3 years ago

I can't reproduce even with your icon theme, sorry. The icon appears white.

ilya-fedin commented 3 years ago

I'll experiment with the theme stuff later and report back.

Have you done your experiments?

ghost commented 3 years ago

I'll experiment with the theme stuff later and report back.

Have you done your experiments?

Yeah!, so I tried messing around with themes and the icon changes but the color still stays dark unfortunately :(. Something might've broke it during an update.

Seems to be my issue tho not telegrams.

ilya-fedin commented 3 years ago

You can try tdesktop from official website to exclude broken settings of system Qt

ghost commented 3 years ago

You can try tdesktop from official website to exclude broken settings of system Qt

Boom. I installed the telegram-desktop-bin package from the AUR instead, icon is white now!

ilya-fedin commented 3 years ago

Yeah, it contains the official binary from official website. So something is wrong with Qt settings, probably with plugins used via QT_QPA_PLATFORMTHEME/QT_STYLE_OVERRIDE (static binary can't load these plugins, so it's not affected) :thinking:

Aokromes commented 3 years ago

so, close?

ilya-fedin commented 3 years ago

so, close?

yeah, it is an issue with system configuration

ghost commented 3 years ago

I'm having the exact same issue in Linux Mint 20 Xfce, just since the last update. Tray icon is black (when it was previously the correct color) despite system icon settings. Using 2.7.1

ilya-fedin commented 3 years ago

@Skaalgard can't confirm изображение

ghost commented 3 years ago

I'm not sure why I'd go through the trouble of lying about this, but alright. This seems to be an area of contention whenever this issue is brought up.

Screenshot_2021-04-11_22-52-48

Screenshot_2021-04-11_22-53-08

Screenshot_2021-04-11_22-52-48

ilya-fedin commented 3 years ago

QT_QPA_PLATFORMTHEME value and installation source would be more valuable than neofetch

ilya-fedin commented 3 years ago

Ah, no, it's valuable actually, Icons: ePapirus [GTK2], Mint-Y [GTK3] shows the culprit. You should fix icon theme desynchronization.

ghost commented 3 years ago

Alright, so how does one fix this?

ghost commented 3 years ago

And why did it work until last update?

ilya-fedin commented 3 years ago

I don't know why it did work, you haven't provide information I requested yet so I have no idea, but this was just a luck since your system is definitely misconfigured.

ilya-fedin commented 3 years ago

Alright, so how does one fix this?

Synchronize your toolkit settings (GTK2, GTK3, Qt).

ghost commented 3 years ago

Can you point me in the right direction on how to do that? Searching around for "synchronize toolkit settings xfce" doesn't yield much.

ilya-fedin commented 3 years ago

Can you point me in the right direction on how to do that?

I guess Xfce sets the settings only for gtk2. So you need to manually edit gtk3's settings.ini. For Qt you should check QT_QPA_PLATFORMTHEME value, it should point which tool you should use to configure Qt.

ghost commented 3 years ago

In /etc/gtk-3.0?

ilya-fedin commented 3 years ago

~/.config/gtk-3.0

ghost commented 3 years ago

There is no settings.ini file in this directory. Should I create one?

ilya-fedin commented 3 years ago

https://wiki.archlinux.org/index.php/GTK#Configuration

etircopyh commented 3 years ago

There is no settings.ini file in this directory. Should I create one?

You should be more aware of the system you're using.

ghost commented 3 years ago

You should be more aware of the system you're using.

Thank you for this novel, productive, and helpful reply. Time well spent.

ghost commented 3 years ago

https://wiki.archlinux.org/index.php/GTK#Configuration

Thank you, this was very helpful. I was able to synchronize gtk2/3 with this. Tray icon is still dark, but we'll see if this persists after a reboot.

ilya-fedin commented 3 years ago

It can't read the changes on the fly, but should read the new configuration if restart the application.

ghost commented 3 years ago

I restarted and tray icon is still dark. I'm still poking around to see what else I can do.

ilya-fedin commented 3 years ago

It would be a way easier to find the cause if you show QT_QPA_PLATFORMTHEME value and say where you installed tdesktop from

ghost commented 3 years ago

I installed it from my distro repository. Installing the official binary from the website caused other display issues.

I'm looking around to find out how to get the value of this to you.

ilya-fedin commented 3 years ago

I installed it from my distro repository.

This couldn't be the true since Mint 20 is based on Ubuntu 20.04 (Focal) and it has only 2.0.1 and 2.1.7: https://packages.ubuntu.com/focal/telegram-desktop https://packages.ubuntu.com/focal-updates/telegram-desktop

Installing the official binary from the website caused other display issues.

Which display issues?

ghost commented 3 years ago

It's a flatpak, which is included in my distro software repository.

The official binary had issues with icons not following system theme at all, cursors changing to not follow theme when over Telegram window, etc. The tray icon issue is the only problem i've had with the flatpak and even then only after the latest update.

ilya-fedin commented 3 years ago

I think it's worth to try now, since you fixed gtk3 settings. And you still haven't shown QT_QPA_PLATFORMTHEME value. :confused:

ghost commented 3 years ago

I am unsure how to find this for you. I've been looking it up. I didn't want to ask yet another stupid question.

ilya-fedin commented 3 years ago

am unsure how to find this for you.

echo $QT_QPA_PLATFORMTHEME

ilya-fedin commented 3 years ago

I didn't want to ask yet another stupid question.

it's better than ignoring questions...

ghost commented 3 years ago

The value is qt5ct

ghost commented 3 years ago

I installed it from my distro repository. Installing the official binary from the website caused other display issues.

I'm looking around to find out how to get the value of this to you.

I did not ignore your question.

ilya-fedin commented 3 years ago

The value is qt5ct

So run qt5ct from application menu (or from terminal) and configure it

ilya-fedin commented 3 years ago

Official binary can read qt5ct settings, but flatpak doesn't, so it reads settings from gtk3 most likely

ghost commented 3 years ago

In qt5ct, it's set to "gtk2," so I don't know what the issue is there.

ilya-fedin commented 3 years ago

But flatpak packages can't read gtk settings from configs due to sandbox, gtk stylizing in flatpak works only when any X Settings daemon is running (like gnome-settings-daemon, mate-settings-daemon, xsettingsd), Xfce probably doesn't have one, so you should install (it should be in your distro repos) & configure xsettingsd

ilya-fedin commented 3 years ago

In qt5ct, it's set to "gtk2," so I don't know what the issue is there.

gtk2 is a widget theme, while you need to check whether icon theme is chosen right (it's in a separate tab in the configurator). This should configure look'n'feel of official binary.

ghost commented 3 years ago

With the official binary, the icon is a blue Telegram logo and it doesn't follow the icon theme at all. I'd frankly rather deal with the dark icon. I'll let you know if the problem is corrected after a reboot.