On Fri, 16 May 2025 23:02:30 GMT, Andy Goryachev <ango...@openjdk.org> wrote:

> It is weird that we have to add third-party specific code to JavaFX as a 
> workaround - why doesn't macOS provide a general purpose API for this?

Normally an input method is designed for a specific language and is bundled 
with a collection of keyboard layouts. The input method is an active blob of 
code but the keyboard layouts are basically big passive tables mapping hardware 
key positions to characters. It appears that Keyman is trying to use one input 
method that works with all of its layouts. It's not producing the corresponding 
data tables; the OS just sees the same Roman table when it generates events. 
We're basically working around that mis-match.

To really do this right Keyman would either have to create new layout tables 
on-the-fly (assuming they can, I've never tried it) or use a low-level event 
tap to re-write the keyboard events (assuming they can, I've never tried it). I 
suspect the API's are available but are probably a devil to get right.

-------------

PR Comment: https://git.openjdk.org/jfx/pull/1805#issuecomment-2887887550

Reply via email to