RFR: 8320912: IME should commit on focus change

Andy Goryachev angorya at openjdk.org
Wed Jan 31 20:10:11 UTC 2024


On Tue, 30 Jan 2024 20:32:36 GMT, Martin Fox <mfox at openjdk.org> wrote:

> This is a Mac only bug. If the user was in the middle of IM text composition and clicked on a different node the partially composed text was left in the old node and the IM window wasn't dismissed. This PR implements the existing finishInputMethodComposition call so it can commit the text and dismiss the IM window before focus moves away from the node where composition was taking place.
> 
> This PR changes the implementation of `unmarkText` to match what we want and what Apple says it should do ("The text view should accept the marked text as if it had been inserted normally"). With that said I haven't found an IME that calls this routine.

Another problem I see, and it might be a totally separate issue, is that sometimes when I launch the Monkey Tester and switch to Japanese input, TextField is still receives US input, despite the IME window appearing.

When this happens, the IME window appears somewhere in a corner, in another screen.  It is also difficult to reproduce.  I first thought it might be related to

[JDK-8324666](https://bugs.openjdk.org/browse/JDK-8324666) JFXPanel: Japanese IME window initially shown in the corner (Windows) 

except the latter is a JFXPanel issue on Windows.

(it's also possibly I am doing something wrong, though I am doing  a clean gradle build, followed by a full refresh and rebuild in Eclipse)

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

PR Comment: https://git.openjdk.org/jfx/pull/1356#issuecomment-1919862497


More information about the openjfx-dev mailing list