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

[Bug] Floating windows from ImHex are unknown to to the desktop environment and not brought back to front when switching to ImHex #1026

Closed
1 task
VorpalBlade opened this issue Apr 10, 2023 · 13 comments
Labels
bug Something isn't working

Comments

@VorpalBlade
Copy link

Operating System

Linux

What's the issue you encountered?

If most programs have more than one window open, they will show up in the taskbar (grouped with a green plus symbol). Here is an example of VS Code in the KDE taskbar:
image

Some programs, such as ImHex and Gimp with floating toolbars doesn't do this. However, if I bring gimp to the front, all it's floating windows are also brought to front. This is not true for ImHex. Only the main window is brought to front. Other windows are lost behind programs and can only be seen by minimizing those programs.

How can the issue be reproduced?

  1. Use KDE Plasma (maybe, I haven't tried other DEs) on X11 (haven't tried Wayland, it doesn't run properly on my system).
  2. Launch ImHex.
  3. Open a floating window.
  4. Switch to another program.
  5. Switch back to ImHex.

Notice that floating windows are still below the other program.

ImHex Version

1.28.0

ImHex Build Type

  • Nightly or built from sources

Installation type

Official .pkg.zst Arch package from GitHub

Additional context?

  • Arch Linux
  • nVidia GTX 1070
  • KDE Plasma 5.27.4
@VorpalBlade VorpalBlade added the bug Something isn't working label Apr 10, 2023
@WerWolv
Copy link
Owner

WerWolv commented Apr 10, 2023

Hey
There's an ImGui setting that can toggle this behaviour and it's enabled right now.

As you can see it works fine on Windows:
image
And on Gnome using Wayland:
image

X11 is in general much better supported than Wayland so this is a bit weird. Maybe KDE needs extra stuff for this to work?

If other programs can do it correctly on your system, I assume this is an ImGui (or potentially GLFW?) issue and should be reported there.

@WerWolv
Copy link
Owner

WerWolv commented Apr 10, 2023

Actually, I just tried it on my Steam Deck which runs KDE through X11 and it does "work" there. It appears in the task bar as a new entry without a proper name or icon set though, it just uses the default X11 icon.
Does that not happen on your system? In any case this is almost definitely an ImGui issue

@jumanji144
Copy link
Collaborator

jumanji144 commented Apr 10, 2023

image
Works for me, well it doesnt display the correct name tho

Ubuntu 23, Kernel 6.1.0, KDE Plasma through X11

(fresh nighlty from website btw)

@VorpalBlade
Copy link
Author

I solved one mystery but found 4-ish others:

  • The generic X11 window icon in the system tray is the extra windows from ImHex. For some reason it is not associating with the main window or the program correctly. Missed that before, but still seems a bit buggy (that bit was not quite as buggy as I thought it was though).
  • No difference with the nightly pkg.zst downloaded from the website

But then I got this weirdness when opening the program:
image
Trying to close this Window was really buggy though, I had to close it around 5 times, with it once showing up duplicated.

Then there was soo much weird behaviour I ended up recording a short screencast to show it off instead: imhex_issues.mkv.zip

  • The Disassembler window is then stuck in one corner and not responding to dragging it by the title bar
  • When trying to drag that Disassembler I would grab things from the main window behind it. Can't close it either.
  • Opening the disassembler window makes the taskbar stop being translucent (it gets darker)? What?
  • Before the recording (and before I opened vs code to act as the "other program", minimising via clicking on the task bar would sometimes minimise the main window, sometimes the constant window. In the recording this seems to work normally.

There is probably at least a handful of different bugs going on here, and they should be reported separately. But in the current state I don't think I'm going to continue using ImHex (sorry about that).

@VorpalBlade
Copy link
Author

Here is another broken one: When dragging windows quickly they shudder and sometimes it just stops dragging even though I'm still holding down the mouse button. I tried recording it, but it seems the issue is less pronounced while OBS is running. It was much much worse before starting the screencast:

imhex_shudder.mkv.zip

@WerWolv
Copy link
Owner

WerWolv commented Apr 10, 2023

One thing I can maybe recommend you is to disable the Enable multi window support setting in the Inteface tab of the settings. I need to see if there's some fix for this weirdness but this is absolutely all caused by ImGui.

The shaking of the window happens when your computer can't render ImGui at the native frame rate of your monitor. If you have a monitor with a high refresh rate, you can try increasing the FPS limit setting in the same settings tab. Recording improved this because it most likely locked the frame rate of everything to 60 FPS

@VorpalBlade
Copy link
Author

Hm, one monitor is 75 Hz native (was a find for cheap at a second hand store), the other is 60 Hz. I run both as 60 Hz because:

  • Nvidia doesn't support FreeSync over HDMI (which is what I would need for the 75 Hz monitor)
  • Video playback on the 75 Hz monitor is just awful.
  • Things get really weird with mixed framerate in general in X11.

Things do seem a little more stable without multi monitor support (from first appearance at least). But I can no longer drag windows outside the main program window. :-( Though perhaps it should be disabled by default (instead of enabled by default) for now, at least on Linux.

@jumanji144
Copy link
Collaborator

Weirdly enough i have the same setup as you, down to the exact monitor arrangement. What NVIDIA GPU do you have? And which drivers, the open or closed ones?

@WerWolv
Copy link
Owner

WerWolv commented Apr 10, 2023

I looked around a bit and it looks like there are indeed issues with the multi viewports on Linux. Mainly caused by both X11 and Wayland reporting wrong positions in some cases.

ocornut/imgui#2117
glfw/glfw#1817

I'm okay with disabling it by default on Linux until these issues are fixed. Might take a long time though, these issues have been open for quite a while. Probably the only reasonable thing I can do for now, sorry

@VorpalBlade
Copy link
Author

I have a 1070 8GB card. Closed drivers, as that is the only viable option for that generation. CPU is a Ryzen 5600X.

  • Not thermal throttling, temps are low. Both have beefy coolers (semi-passive ROG Strix card, and massive BeQuiet tower cooler respectively). And it is cool here in Sweden.

Seems strange that a 1070 would not be able to run ImHex at native speed though. I can run many 3D games at 60 Hz (playing a lot of Satisfactory for example, and it stays locked even with a complex factory build) which I would assume is a much more complicated than a 2D GUI.

@jumanji144
Copy link
Collaborator

i have a 1650 4GB Slim OC card with a Ryzen 5600X. What distro are you using?

@VorpalBlade
Copy link
Author

Arch Linux (it is the only distro that doesn't get in my way and does exactly what I want. This is what happens if you have been using Linux as a daily driver for nearly two decades I guess.)

@jumanji144
Copy link
Collaborator

Yea idk, only difference between your and mine setup is just that i use Kbuntu dev branch and have a different GPU

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants