Skip to content

Problems with Qt implementation of StatusIcons #4027

@johnzhou721

Description

@johnzhou721

Describe the bug

Qt's implemenation of StatusIcons has the following issue:

  • On Wayland, the popup for the menu does not display on left-click in a MenuStatusIcon.
  • On X11, when left-clicking a MenuStatusIcon, the context menu is positioned at the mouse position instead of above the systray like it does when right-clicked.

Steps to reproduce

Run the statusicon example app.

Expected behavior

A status icon is always displayed and above the systray.

Screenshots

No response

Environment

Fedora 42, all packages up-to-date

Logs

No response

Additional context

An outline to fix this is at #3987 (comment); however it was decied against fixing this in #3987 to not scope-creep and/or wait for KStatusNotifierItem support in system-pyside6 to land.

Another blocker is that KStatusNotifierItem's Python bindings are not shipped with Ubuntu, and is not available for people not using system-pyside6, so we'd still have to have an implementation for plain QSystemTrayIcon. How to handle left-click on Wayland is an open issue -- there's no good way for that without using KStatusNotifierItem; my inclination is to either a) do nothing or b) pop up a small window with "Actions" in its menu bar, with the "Actions" hooked up to the menus for that status icon.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugA crash or error in behavior.linuxThe issue relates Linux support.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions