RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-09-28 Thread Martin Fox
There was a mismatch between the way `get_glass_key` generated the Java key code for a given key press and how `getKeyCodeForChar` determined the key code for the matching character. For example, when pressing the plus sign on a US keyboard `get_glass_key` correctly generated `KeyCode.EQUALS` bu

RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-12-13 Thread Martin Fox
The algorithm in `KeyCharacterCombination.match` relies on the call `Toolkit.getKeyCodeForChar` which is difficult to implement correctly. It defies the way most keyboard API’s work and no platform has got it right yet. In particular the Mac and Linux implementations have to resort to a brute-fo

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-11-08 Thread Pankaj Bansal
On Tue, 28 Sep 2021 21:01:13 GMT, Martin Fox wrote: > There was a mismatch between the way `get_glass_key` generated the Java key > code for a given key press and how `getKeyCodeForChar` determined the key > code for the matching character. For example, when pressing the plus sign on > a US ke

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-12-14 Thread Kevin Rushforth
On Mon, 13 Dec 2021 19:46:27 GMT, Martin Fox wrote: > The algorithm in `KeyCharacterCombination.match` relies on the call > `Toolkit.getKeyCodeForChar` which is difficult to implement correctly. It > defies the way most keyboard API’s work and no platform has got it right yet. > In particular

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-12-14 Thread Martin Fox
On Mon, 13 Dec 2021 19:46:27 GMT, Martin Fox wrote: > The algorithm in `KeyCharacterCombination.match` relies on the call > `Toolkit.getKeyCodeForChar` which is difficult to implement correctly. It > defies the way most keyboard API’s work and no platform has got it right yet. > In particular

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-12-15 Thread Martin Fox
On Mon, 13 Dec 2021 19:46:27 GMT, Martin Fox wrote: > The algorithm in `KeyCharacterCombination.match` relies on the call > `Toolkit.getKeyCodeForChar` which is difficult to implement correctly. It > defies the way most keyboard API’s work and no platform has got it right yet. > In particular

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout

2021-12-17 Thread Kevin Rushforth
On Wed, 15 Dec 2021 21:30:41 GMT, Martin Fox wrote: > I've decided that if this PR goes forward we should abandon #672. The changes > in #672 would be bypassed for KeyEvents generated by physical keystrokes. For > a while I thought it would be useful for handling KeyEvents created via the > AP

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v2]

2021-11-10 Thread Martin Fox
> There was a mismatch between the way `get_glass_key` generated the Java key > code for a given key press and how `getKeyCodeForChar` determined the key > code for the matching character. For example, when pressing the plus sign on > a US keyboard `get_glass_key` correctly generated `KeyCode.EQ

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v3]

2021-11-10 Thread Martin Fox
> There was a mismatch between the way `get_glass_key` generated the Java key > code for a given key press and how `getKeyCodeForChar` determined the key > code for the matching character. For example, when pressing the plus sign on > a US keyboard `get_glass_key` correctly generated `KeyCode.EQ

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v3]

2021-12-05 Thread Pankaj Bansal
On Wed, 10 Nov 2021 18:48:04 GMT, Martin Fox wrote: >> There was a mismatch between the way `get_glass_key` generated the Java key >> code for a given key press and how `getKeyCodeForChar` determined the key >> code for the matching character. For example, when pressing the plus sign on >> a U

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v3]

2021-12-05 Thread Martin Fox
On Wed, 10 Nov 2021 18:48:04 GMT, Martin Fox wrote: >> There was a mismatch between the way `get_glass_key` generated the Java key >> code for a given key press and how `getKeyCodeForChar` determined the key >> code for the matching character. For example, when pressing the plus sign on >> a U

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v4]

2021-12-13 Thread Martin Fox
> There was a mismatch between the way `get_glass_key` generated the Java key > code for a given key press and how `getKeyCodeForChar` determined the key > code for the matching character. For example, when pressing the plus sign on > a US keyboard `get_glass_key` correctly generated `KeyCode.EQ

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v4]

2021-12-13 Thread Martin Fox
On Mon, 13 Dec 2021 19:40:47 GMT, Martin Fox wrote: >> There was a mismatch between the way `get_glass_key` generated the Java key >> code for a given key press and how `getKeyCodeForChar` determined the key >> code for the matching character. For example, when pressing the plus sign on >> a U

Re: RFR: 8273743: KeyCharacterCombination for "+" does not work on US QWERTY keyboard layout [v2]

2021-12-16 Thread Martin Fox
> The algorithm in `KeyCharacterCombination.match` relies on the call > `Toolkit.getKeyCodeForChar` which is difficult to implement correctly. It > defies the way most keyboard API’s work and no platform has got it right yet. > In particular the Mac and Linux implementations have to resort to a