Problem with accented characaters on Mac


#1

Hello,

I have a problem which I couldn’t solve myself. Maybe you can help me…

There is a KeyListener object in my application which listens the keys the user presses. On Windows platform with Spanish keyboard layout, when the user presses the accent mark character (`) and then the (e) key, the KeyListener receives a KeyPress for the (è) key. That’s perfect.

Unfortunately the Mac version works differently. The KeyListener receives only the plain unaccented (e) key and the accent marks are lost.

There should be a solution to catch the accented characters on Mac platform, but how?


#2

Hmm… After inheriting TextInputTarget class, my component now receives accented characters through insertTextAtCaret methode. I’m closer to the solution…