Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main window reported as Python3 in Gnome 3 #169

Open
szpak opened this issue Oct 8, 2020 · 5 comments
Open

Main window reported as Python3 in Gnome 3 #169

szpak opened this issue Oct 8, 2020 · 5 comments

Comments

@szpak
Copy link

szpak commented Oct 8, 2020

The main dnfdragora window is reported as Python3 (instead of dnfdragora) in Gnome 3:

image

image

$ rpm -qa | grep dnfdragora
dnfdragora-2.1.0-2.fc32.noarch
dnfdragora-updater-2.1.0-2.fc32.noarch
@Conan-Kudo
Copy link
Member

That's odd, because we set the title in the application:

yui.YUI.app().setApplicationTitle(_("Software Management - dnfdragora"))

And the desktop file has the correct name as well:

@szpak
Copy link
Author

szpak commented Oct 8, 2020

The Window is titled ok:
image

however, Gnome 3 reports it as Python3 showing open apps.

When I open it from the launcher it behaves the same (Python3 when launched), even though I see dnfdragora in the application search window - taken from the desktop file.

@szpak
Copy link
Author

szpak commented Oct 8, 2020

Based on the SO knowledge, it seems that Gnome Shell uses WMClass to determine the application name.

For dummy "hello world" Gnome 3 app, adding the following line did a trick:

self.set_wmclass ("My App", "My App")

image

Maybe it could also achieved with yui.

@anaselli
Copy link
Collaborator

anaselli commented Oct 8, 2020

that says

The set_wmclass() method sets the X Window System "class" and "name" hints for a window. Applications should not call this method. According to the ICCCM, you should always set these to the same value for all windows in an application, and PyGTK sets them to that value by default, so calling this method is sort of pointless. However, you may want to call the set_role() method on each window in your application, for the benefit of the session manager. Setting the role allows the window manager to restore window positions when loading a saved session.

Anyway we don't use PyGTK but libyui-gtk so maybe we must check a way to fix it there or into bindings maybe?

@alastortenebris
Copy link

alastortenebris commented Mar 3, 2022

This might be related, but the KDE Wayland taskbar groups mcomix3, another python3 based app, with dnfdragora. I don't think it's just GNOME.

Also dnfdragora's icon doesn't appear in the KDE taskbar but that might be a KDE issue.

This is on Fedora 35's dnfdragora 2.1.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants