yglukhov / nimx

GUI library
MIT License
1.08k stars 76 forks source link

IME input does not work in the webGL demo #521

Open nico-abram opened 10 months ago

nico-abram commented 10 months ago

I noticed 2 issues trying to input japanese text in the live webgl demo linked in the readme: 1) Normally, typing "nani" with japanese hiragana looks like this: input n -> text= n input a -> text=な (hiragana for na) input n -> text=なn input i -> text=なに (na + ni) However, this becomes nあnい (あ=a and い=i )in the webgl demo: imagen

2) The second problem is IME input not working. Normally, typing なに (hiragana, basically phonetic alphabet) brings up a list that the user can then pick from to choose a different way of writing that reading (e.g the kanji 何): imagen However, while on the webgl demo the IME does popup, it seems to only capture a single keypress (i.e inputting いい only shows a single い so 良い(いい)does not show up as an option in the IME list). Another problem is that pressing space or tab do not work with the IME (normally that lets you cycle and choose an option without having to use the mouse). Finally, clicking on one of the IME options with the mouse does not modify the text in the textbox at all.

Tested on firefox nightly.

yglukhov commented 10 months ago

Thanks for the report. The js mode in nimx is no longer maintained in favor of wasm. The webgl demo was compiled a long time ago when js mode was supported. Regardless of that, i unfortunately don't know how IME works, as I don't use languages requiring it. It will probably require some effort to implement on all the platforms nimx supports, and I can't do that right now. That said I will provide any help to anyone willing to implement it.