libgdx: Android - Google US English keyboard backspace not working

Android 4.3.1 Nexus 7 (2013) When in a text field, backspace on the Google US English keyboard (I believe it’s default for this device) does nothing. I wrote the below code in an InputProcessor to try to chase the bug, but it never even catches the backspace.

public boolean keyDown(int keycode) {
            Tools.log.debug("keyDown: " + keycode);

I switched to another keyboard and backspace was caught just fine. Also verified google keyboard backspace works in other apps.

However, I’m not sure the problem is with libgdx.

About this issue

  • Original URL
  • State: closed
  • Created 11 years ago
  • Comments: 24 (12 by maintainers)

Most upvoted comments

I have this filter on TextField:

            public boolean acceptChar(TextField f, char c) {                
                return Character.isLetterOrDigit(c);                    
            }

When I try to put the letter in other language it doesnt typed, its OK. But than i can delete the text EXACTLY on the length of typed chars.

Example:

  1. I set the text in show() method: “android”.
  2. render()
  3. click on field. try to delete text. Backspace doesnt works.
  4. type filtered symbols, for example “ХУЙ”. They are not displayed and typed. OK
  5. Now i can delete 3 symbols! (the length of chars which i typed before but which were filtered).