Which demo project is affected:
Multiplayer Bomber
OS/device including version:
Mac OSX Mojave 10.14.6 (18G103)
Issue description:
By tapping on a LineEdit the virtual keyboard pops up but it doesn't work if you type/delete something
I also tried to create a new scene with a Control node and a LineEdit.
BTW It works building from 3.1.2
I tried it out and it too doesn't work (Arch Linux and a Huawei P Smart)
Please confirm Godot version that you are having the issue on?
The Godot version is 3.2
I can also confirm LineEdit is not accepting input from Android's virtual keyboard. TextEdit does work.
Version 3.2
3.1.2 works just fine
I just had a look to check whether it could be a regression from #29948 (thinking maybe it could be classifying the line edit key input as from a game device (gamepad, joystick etc)). However looking at the code I don't think the PR change could cause this, it classifies more devices as keyboards, and doesn't add any more to the game devices. That doesn't mean there wasn't an existing problem with classification though.
For anyone who can debug the Android version, It is worth checking that any input is coming in at all to onKeyDown. It is also possible some changes to gestures or further up has prevented input getting to onKeyDown. That's assuming LineEdit uses normal input, I can also see a GodotTextInputWrapper
. (Sorry I cannot work on this at the moment)
I anyone is up for testing older versions, it would be great to pinpoint the first alpha/beta or RC release where the regression happened: https://downloads.tuxfamily.org/godotengine/3.2/
Note that you need to install matching export templates to export to Android.
Looking at LineEdit
it looks like max_length
could be responsible for it:
https://github.com/godotengine/godot/blob/1361fa71c419a44c9a5849a599fa745efe9052cf/scene/gui/line_edit.cpp#L131
Default is 0, which means no limit according to the documentation. But maybe in the virtual keyboard implementation it actually means no input is accepted?
I'm going to run some tests to confirm.
Related to #35438 ?
It's confirmed, and yes it's due to the changes in PR #35438 (CC @MadEqua).
The fix is very simple, so I'm going to propose a PR soon.
Workaround
You can set Max Length
property in your LineEdit
to a large number instead of 0.
Hi, thanks for your great work!
To apply this patch before it is actually released officially, do we have to build the export templates or the main engine we use to export the game?
@tinxx Yes, in general, you have to recompile all the export templates you plan to use. However, since this fix only affects Android, you only have to recompile the Android export templates.
@Calinou, thanks for the quick response!
So just to be sure if it makes sense to set up the whole Android build system:
Can we expect to get new official export templates prior to a new Godot engine version? And if so, will if be announced anywhere?
Can we expect to get new official export templates prior to a new Godot engine version?
Outside of alphas/betas/release candidates, no. We don't have official daily builds yet, but you can use these builds provided by yours truly. These are provided on a best-effort basis, of course.
Most helpful comment
It's confirmed, and yes it's due to the changes in PR #35438 (CC @MadEqua).
The fix is very simple, so I'm going to propose a PR soon.
Workaround
You can set
Max Length
property in yourLineEdit
to a large number instead of 0.