telegramdesktop / tdesktop

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

Notification counter in system tray not working #10264

Closed beglort closed 3 years ago

beglort commented 3 years ago

Steps to reproduce

  1. Install telegram-desktop 2.5.7.r4
  2. open telegram desktop and be sure notifications are enabled
  3. receive some messages

Expected behaviour

The notification counter in system-tray should become red and show a number of received messages

Actual behaviour

The icon tray doesn't show any red dot or any number of received messages

Configuration

Operating system: Manjaro 20.2.1 + kernel 5.10.11 + DE: KDE 5.78.0 / Plasma 5.20.5

Version of Telegram Desktop: 2.5.7.r4 Latest working version of Telegram Desktop: 2.5.5.r1

Installation source (Linux Only) - package from distribution, repository: community

Used theme: GTK Theme: Breeze [GTK2/3] Breeze Icon theme Plasma theme: Breeze

Output if launched from terminal

Screenshot_20210129_181935

ilya-fedin commented 3 years ago

10263 #10251

beglort commented 3 years ago

10263 #10251

None of the above seems to apply with kde plasma, one is about mate desktop and another about cinnamon. I tried all the defaults theme and downloaded many others. The new tray icon works only when I use a monochrome icon theme: it appears just as a simple dot (expected behaviour)

expected Screenshot_20210130_003326

Breeze theme doesn't use a monochrome icon, nor monochrome was used by any other theme I tried, still the counter badge is not present.

not working Screenshot_20210130_003356

ilya-fedin commented 3 years ago

@beglort looks like it is a bug in KDE's kiconthemes framework. Unfortunately, we can't fix third-party libraries, I recommend to install the binary from https://desktop.telegram.org where we can control used libraries.

beglort commented 3 years ago

@ilya-fedin thank you, I will report the issue to KDE then, I'm in the unstable branch so I guess as soon as the other users will upgrade plasma the problem will be noticed. For now I use a theme with monochrome since is the only one working

edit: I can confirm that the binary from the site is working as intended

ilya-fedin commented 3 years ago

@beglort it's worth to mention in the report that the bug is that QIcon::hasThemeIcon("telegram-attention-panel") returns true even when only telegram icon is present in the icon theme.

ilya-fedin commented 3 years ago

I'm in the unstable branch so I guess as soon as the other users will upgrade plasma the problem will be noticed.

This bug is not only in unstable branch of Plasma, it is reproducible in stable versions as well.

beglort commented 3 years ago

@beglort it's worth to mention in the report that the bug is that QIcon::hasThemeIcon("telegram-attention-panel") returns true even when only telegram icon is present in the icon theme.

I will do, thank you for all the info

soredake commented 3 years ago

@ilya-fedin same bug with flatpak version+kubuntu 20.10, icon worked in previous versions of telegram flatpak, IIRC

ilya-fedin commented 3 years ago

We can't do anything except of waiting a fix from KDE side

soredake commented 3 years ago

@beglort do you filled bugreport to kde?

beglort commented 3 years ago

@beglort do you filled bugreport to kde?

Yes I did and it was closed, it seems solved in frameworks 5.79. I can't confirm yet, the best thing is to wait or use the version from telegram.org

Here is the bug filed on kde: https://bugs.kde.org/show_bug.cgi?id=432293

ilya-fedin commented 3 years ago

https://bugs.kde.org/show_bug.cgi?id=432293

So, they decided to "fix" this by providing monochrome icons instead of fixing actual bug in kiconthemes? :see_no_evil: Maybe we should do QApplication::setDesktopSettingsAware(false) on KDE in order to avoid injecting of their libraries...

soredake commented 3 years ago

They fixed it, not ideal, but something. изображение

beglort commented 3 years ago

https://bugs.kde.org/show_bug.cgi?id=432293

So, they decided to "fix" this by providing monochrome icons instead of fixing actual bug in kiconthemes? see_no_evil Maybe we should do QApplication::setDesktopSettingsAware(false) on KDE in order to avoid injecting of their libraries...

I thought that with frameworks 5.79 we could choose between the monochrome and the original status icon since an user asked it https://invent.kde.org/frameworks/breeze-icons/-/merge_requests/81 and received a positive reply.
Then if is not the bug shouldn't be closed, a message counter is important

beglort commented 3 years ago

They fixed it, not ideal, but something. изображение

So this is the new plasma "fix"? isn't there an option to have a real counter? Not really what I was asking when I filed the bug there 🙄

ilya-fedin commented 3 years ago

and received a positive reply

I don't see one on the link. I see only suppositions.

beglort commented 3 years ago

I see only suppositions.

I thought it was this: "There is, you can specify an Icon by name and an OverlayIcon by pixmap. This was actually broken on plasma side but seems to be fixed now." But it seems I just misunderstood it.

ilya-fedin commented 3 years ago

They meant applications developers by "you". And no, tdesktop doesn't support OverlayIcon by three reasons:

  1. It breaks color scheme support anyway
  2. The counter is unreadable with it
  3. It's supported only by Plasma, while tdesktop aims to be DE-neutral.
beglort commented 3 years ago

They meant applications developers by "you". And no, tdesktop doesn't support OverlayIcon by three reasons:

1. It breaks color scheme support anyway

2. The counter is unreadable with it

3. It's supported only by Plasma, while tdesktop aims to be DE-neutral.

OK, I got it. You've been very clear thank you. So my best chance now is to use the version from the official telegram site (what I'm doing) or just accept the new plasma "improvement"

ilya-fedin commented 3 years ago

So my best chance now is to use the version from the official telegram site (what I'm doing) or just accept the new plasma "improvement"

Yeah. And you will should remove these new icons as soon as they land you in order to have the counter even on official binary.

beglort commented 3 years ago

So my best chance now is to use the version from the official telegram site (what I'm doing) or just accept the new plasma "improvement"

Yeah. And you will should remove these new icons as soon as they land you in order to have the counter even on official binary.

Thank you for the tips. I guess once these changes reach more kde users there will be many help requests on the various forum. I understand that monochrome is nicer, but the counter is a big help indeed

ilya-fedin commented 3 years ago

but the counter is a big help indeed

Isn't counter on the taskbar icon enough?

beglort commented 3 years ago

but the counter is a big help indeed

Isn't counter on the taskbar icon enough?

Not really, because when I use a auto hiding dock it won't be shown. Some might just set telegram to start when system start and don't have the icon on the taskbar, but only in tray. Still the system tray is the place where users look for notifications, and the red dot is also easier to check than the blue dot in the blue taskbar icon. These are just my opinions but I imagine other can have similar reasons

Shatur commented 3 years ago

@ilya-fedin, why the issue was closed? It worked in 2.5.5 (I currently downgraded to this version):

изображение изображение

But in the latest version it displays only a single dot. If I change theme without dot indicator, then I will have a default Telegram icon instead of themed (as it was in 2.5.5).

ilya-fedin commented 3 years ago

Sorry, but you can't have counter on monochrome icon anymore. Since @john-preston doesn't allow to add an option for this, there's no other way except of don't add counter for all users of monochrome icons.

Shatur commented 3 years ago

Thanks for the fast answer!

Since @john-preston doesn't allow to add an option for this

@ilya-fedin , what's the problem with displaying counter on a monochrome icon?

ilya-fedin commented 3 years ago

what's the problem with displaying an icon on a monochrome icon?

what icon on a monochrome icon?

Shatur commented 3 years ago

@ilya-fedin, sorry, I meant counter :)

ilya-fedin commented 3 years ago

sorry, I meant counter :)

https://github.com/telegramdesktop/tdesktop/issues/10239

Shatur commented 3 years ago

10239

@ilya-fedin, thanks for the info. I don't know why it was broken for @AndydeCleyre, but I also use Arch with KDE and had a nice-looking system tray: изображение Can we have an option that allows to display a counter on monochrome icons (e.g. return behavior from 2.5.5)?

ilya-fedin commented 3 years ago

Can can we have an option that allows to display a counter on monochrome icons (e.g. returns behavior from 2.5.5)?

Since @john-preston doesn't allow to add an option for this

Shatur commented 3 years ago

Since @john-preston doesn't allow to add an option for this

@ilya-fedin, I understand, I meant is there just a chance to reconsider this decision? Apparently, I'm not the only one complaining about the new change.

ilya-fedin commented 3 years ago

I understand, I meant is there just a chance to reconsider this decision?

i don't know... ask @john-preston

Shatur commented 3 years ago

i don't know... ask @john-preston

Opened a proposal for it in #10407.

orivej commented 3 years ago

For the reference Telegram has stopped showing the counter in the tray since #10142.

github-actions[bot] commented 3 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.