Wednesday, 4 November 2020

Writing a Android System app that uses KeyEvents to insert text into a text field. But special symbols dont work?

So I could use a combination of CTL+ for control characters , SHIFT+ for Upper case letters like A ,B and characters like !,{ (i.e Basic Latin and punctuation characters) .

However I am not able to find the combination in Android for symbols like Ã,dž ... etc. Ubuntu Uses a combination of CTRL+SHIFT+U .. followed by four numbers that generate the symbol, but that does not seem translatable to Android.

TL;DR : How to generate special symbols using Android KeyEvents and KeyCharacter Map?

Update : Learnt about this resource : https://source.android.com/devices/input/key-character-map-files and it looks like I will have to use a key combo and they talk about a magic hex input , but I have tried using

1111 followed by Alt+Shift+X ( qwerty.kcm file contains this) ... But it does not type out the unicode symbol to the corresponding 1111.

Can someone help with this please ?



from Writing a Android System app that uses KeyEvents to insert text into a text field. But special symbols dont work?

No comments:

Post a Comment