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

Can't rename any node with Godot 4 Beta15 under KDE Plasma Wayland session #72074

Closed
dark-elf1 opened this issue Jan 25, 2023 · 17 comments · Fixed by #72497
Closed

Can't rename any node with Godot 4 Beta15 under KDE Plasma Wayland session #72074

dark-elf1 opened this issue Jan 25, 2023 · 17 comments · Fixed by #72497

Comments

@dark-elf1
Copy link

dark-elf1 commented Jan 25, 2023

Godot version

v4.0.beta15.official [4fa6edc] and v4.0.beta.custom_build [1bf7b84]

System information

openSUSE Tumbleweed 20230125, KDE Plasma 5.26.5, Wayland session

Issue description

wayland_input_bug.mp4

It's not possible to rename any node while using wayland session under my linux distro. Using Godot 4 beta15. Tried changing keyboard layout and same result. If I swith to X11 session then it works. Also beta14 doesn't have this problem with wayland session.

Steps to reproduce

Literally try to rename any node under wayland session with beta15

Minimal reproduction project

n/a

@Calinou
Copy link
Member

Calinou commented Jan 26, 2023

Related to #72012 (fixed in the latest master branch).

Can you test this on the latest master branch? See Compiling on Linux.

@Calinou Calinou closed this as not planned Won't fix, can't repro, duplicate, stale Jan 26, 2023
@github-project-automation github-project-automation bot moved this from To Assess to Done in 4.x Priority Issues Jan 26, 2023
@Calinou Calinou reopened this Jan 26, 2023
@Calinou Calinou moved this from Done to To Assess in 4.x Priority Issues Jan 26, 2023
@beicause
Copy link
Contributor

I test this on the master. #72012 is fixed, but I still cannot rename any node.

@dark-elf1
Copy link
Author

Related to #72012 (fixed in the latest master branch).

Can you test this on the latest master branch? See Compiling on Linux.

As suggested I compiled the engine from master[cc7aa72] but still can't rename any node under wayland session.

@bruvzg
Copy link
Member

bruvzg commented Jan 26, 2023

Is it only an issue with popups (e.g., rename / inspector properties), or with any input controls (e.g., script editor)?

@dark-elf1
Copy link
Author

dark-elf1 commented Jan 26, 2023

Is it only an issue with popups (e.g., rename / inspector properties), or with any input controls (e.g., script editor)?

Script editor works, I can type in it. As for the node if i try with F2 shortcut for renaming or selecting it with right click and do rename on popup it selects the node but won't work. It completely ignores any input from keyboard. Can't delete the or rename the node's name.
Edit: I forgot to mention that the mouse actions which are invoked by right clicking on the node such as cut,copy, paste, select all, clear, undo, and redo do work. Keyboard input doesn't do anything..

@bruvzg
Copy link
Member

bruvzg commented Jan 27, 2023

I was not able to reproduce it with Gnome /Wayland session on PopOS 22.04.

@dark-elf1
Copy link
Author

I test this on the master. #72012 is fixed, but I still cannot rename any node.

May I ask what distro and what desktop environment do you use? (what did you use for test?)

I was not able to reproduce it with Gnome /Wayland session on PopOS 22.04.

Interesting. I'm currently using KDE Plasma with openSUSE. I will also try to see if the issue can be reproduced on Gnome/Wayland session with openSUSE.

@beicause
Copy link
Contributor

May I ask what distro and what desktop environment do you use? (what did you use for test?)

I also use KDE Plasma on Ubuntu 22.04

@dark-elf1
Copy link
Author

It seems that the issue can't be reproduced on Gnome/Wayland with openSUSE. So this is a KDE Plasma/Wayland specific issue?

@dark-elf1 dark-elf1 changed the title Can't rename any node with Godot 4 Beta15 under wayland session Can't rename any node with Godot 4 Beta15 under KDE Plasma Wayland session Jan 27, 2023
@akien-mga akien-mga pinned this issue Jan 28, 2023
@zephyroths
Copy link

zephyroths commented Jan 28, 2023

I'm using v4.0.beta16.mono.official [518b9e5] but it still happen, I'm using Arch on KDE Wayland and it still don't work

@dark-elf1
Copy link
Author

After compiling the engine multiple times I think I might have found the commit where this issue started appearing. It's daad4ae. Hope this is an useful information.

@Logical-sh
Copy link

Logical-sh commented Jan 28, 2023

I also am having a similar issue.
I find that trying to rename a node (KDE Arch Wayland Session) doesn't work, and locks up various input until a random amount of time/interactions have passed. Usually by randomly clicking nodes my camera controls work again.
Never seems to break left click selecting, but breaks mmb and typing.

@Logical-sh
Copy link

Losing focus and regaining focus on the main window seems to reliably fix the lockout.

@Logical-sh
Copy link

So actually, the typable editor window is appearing sort of behind the main godot window.
If you shrink godot and move it, you can finish the input.
Kooha-2023-01-28-12-47-22.webm

@clayjohn
Copy link
Member

CC @bruvzg

@Logical-sh
Copy link

I am no expert with godot's source code, today is the first time looking at it, but I'll share incase it helps a more familar dev find the issue faster.

It looks like the sub-window/popup created with the text editor is not receiving focus when it is created. Key events aren't even logged if keys are pressed after double clicking.

Commenting out the following line in display_server_x11.cpp causes it to work correctly on my machine
valuemask |= CWOverrideRedirect | CWSaveUnder;
But I do not think this is necessarily the correct solution as it also makes the input flash black for a second.
I think some of the new checks in the various events checking if it is an input window added in the mentioned commit may just be preventing the window from getting focused correctly.
Once you hit that point, it may come down to differences in behaviors of individual WM at that point (mutter vs kwin for example) as to if the new window is focused since it isn't being explicitly made to focus? Not sure, just my current hypothesis.

@Logical-sh
Copy link

I will also comment, that
window_set_ime_active is being called repeatedly from the
NOTIFICATION_DRAW event of the line_edit.cpp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment