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

€ character cannot be entered #2511

Closed
2 tasks done
Tragen opened this issue Jul 22, 2021 · 9 comments
Closed
2 tasks done

€ character cannot be entered #2511

Tragen opened this issue Jul 22, 2021 · 9 comments

Comments

@Tragen
Copy link

Tragen commented Jul 22, 2021

  • I have read the FAQ.
  • I have searched in existing issues.

Environment

  • OS: Windows
  • scrcpy version: 1.18
  • installation method: Windows zip
  • device model: OnePlus 7T
  • Android version: 11

Describe the bug
When I'm writing a text, everything works, except the € character.
When I press ALTGR+E or CTRL+ALT+E, I get this error in the console.

On errors, please provide the output of the console (and adb logcat if relevant).

[server] WARN: Could not inject char u+20ac
@rom1v
Copy link
Collaborator

rom1v commented Jul 22, 2021

Yes, unfortunately, Android does not support injecting non-ASCII chars on text injection.

It's the same with adb shell input text €.

https://github.com/Genymobile/scrcpy/blob/master/FAQ.md#special-characters-do-not-work
Duplicate of #37.

@Tragen
Copy link
Author

Tragen commented Jul 22, 2021

Are you sure? ASCII doesn't include öäüß and I can enter it.

@rom1v
Copy link
Collaborator

rom1v commented Jul 22, 2021

@Tragen
Copy link
Author

Tragen commented Jul 22, 2021

Thanks. I hope this can be fixed in the future.

@rom1v
Copy link
Collaborator

rom1v commented Oct 27, 2021

Fixed by #2632.

Refs #37 (comment)

@rom1v rom1v closed this as completed Oct 27, 2021
@l1m3r
Copy link

l1m3r commented Jul 9, 2023

AFAIKT this isn't fixed at all with #2632
For Linux yes but not for Windows if you require mirroring mode.
I couldn't find any way to enter €, µ, ² or ³ - not even in --otg --hid-keyboard mode.

Tried

  1. -otg --hid-keyboard -> no mirroring :-(
  2. --serial=<....> because of Add HID keyboard simulation via USB HID over AoAv2 #2632
  3. --prefer-text -> doesn't work.
  4. --raw-key-events -> doesn't work.

Changing the language of the physical OTG keyboard didn't help either.
With 4. I can't get anything else but the English keyboard layout...

@rom1v
Copy link
Collaborator

rom1v commented Jul 9, 2023

@l1m3r Yes, unfortunately, could not be injected from the Android API. I'm also annoyed by that.

With scrcpy --hid-keyboard (scrcpy -K, without --otg), it works, but not on Windows because we can't access USB if adb already uses it (on other platforms this is not a problem).

@l1m3r
Copy link

l1m3r commented Jul 9, 2023

Maybe there's a way around it - One can enter € and so on via copy/paste.

  1. [server] WARN: Could not inject char u+20ac
  2. disable clipboard-sync temporarily (if it's used).
  3. store clipboard content of device temporarily.
  4. set device clipboard to just the character from 1. and paste it.
  5. restore 3.
  6. re-enable 2.

Maybe pausing input during that ^^ (I guess it takes longer than the normal input methods).

@rom1v
Copy link
Collaborator

rom1v commented Jul 10, 2023

@l1m3r I tried something similar in the paste #1426 but I abandoned the idea (see the thread).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants