Alexey-T / CudaText

Cross-platform text editor, written in Free Pascal
Mozilla Public License 2.0
2.39k stars 166 forks source link

[Qt Wayland] `ui_dialogs_in_taskbar__linux` = `false` doesn't work #5515

Open pintassilgo opened 1 month ago

pintassilgo commented 1 month ago
  1. Wayland session.
  2. Launch Cuda Qt (both official Qt5 and Flatpak Qt6 are affected).
  3. Set ui_dialogs_in_taskbar__linux = false and restart Cuda to make sure the change is applied.
  4. Open Command palette.

Expected:

Command palette shouldn't be treated as a separated window i.e. it shouldn't appear as a new window in taskbar, also if you press Alt + Tab you should activate a window of a different app (like webbrowser or whatever).

Current:

Command palette opens as a separated window, with its own tab in taskbar, also if you press Alt+Tab you activate Cuda window, minimizing Command palette.

Gtk is not affected.

I use KDE Plasma, but hopefully any DE running Wayland session is affected when you run Qt Cuda.

Currently, I run Cuda with QT_QPA_PLATFORM=xcb set to avoid this issue. By doing this, I'm launching Cuda as xwayland window instead of native Wayland, so I shouldn't do it. And Cuda xwayland has its own bugs like #5132.

Alexey-T commented 1 month ago
  UiOps.PluginDialogsShowInTaskbar:= cfg.GetValue('ui_dialogs_in_taskbar'+cOptionSystemSuffix, UiOps.PluginDialogsShowInTaskbar);

so, option is applied only to UiOps.PluginDialogsShowInTaskbar which is applied only to PLUGINS dialogs. Cmd Palette is not affected by this flag. it has "never show in taskbar" option. if it shows in taskbar, it seems a Lazarus bug. I cannot see it on Ubuntu 20 with Gnome, Wayland too, qt5 too.

pintassilgo commented 1 month ago

option is applied only to UiOps.PluginDialogsShowInTaskbar which is applied only to PLUGINS dialogs. Cmd Palette is not affected by this flag

Find favorite..., dialog from Favorites plugin, is also affected i.e. creates tab in taskbar, acts as a separated window.

Alexey-T commented 1 month ago

Primitive demo for qt5:

tst-ShowInTaskbar-qt5.zip

run 'project1' app.

press button 2-3 times. do all new windows (created by button) have style "show in taskbar"? they have it "NEVER show in taskbar".

pintassilgo commented 1 month ago

Yes.

image

Alexey-T commented 1 month ago

Pls show me system info. maybe run 'neofetch'.

pintassilgo commented 1 month ago

This is Wayland-only issue. If I run as xwayland i.e. not true Wayland app, there's no issue.

image

Alexey-T commented 1 month ago

'neofetch'? what does it show.

pintassilgo commented 1 month ago

Operating System: openSUSE Tumbleweed 20240310 KDE Plasma Version: 5.27.10 KDE Frameworks Version: 5.115.0 Qt Version: 5.15.12 Kernel Version: 6.7.7-1-default (64-bit) Graphics Platform: Wayland Processors: 12 × AMD Ryzen 5 1600 Six-Core Processor Memory: 31,3 GiB of RAM Graphics Processor: AMD Radeon RX 570 Series

Alexey-T commented 1 month ago

Bugreport for Lazarus https://gitlab.com/freepascal.org/lazarus/lazarus/-/issues/40954