LWJGL Forum

Programming => Lightweight Java Gaming Library => Topic started by: HappyCat on July 26, 2007, 09:31:00

Title: UK Keyboards
Post by: HappyCat on July 26, 2007, 09:31:00
Since updating to v1.1 the Keyboard class no longer seems to recognise that I have a UK keyboard. Prior to v1.1 everything worked fine (the `, @ and £ keys were in the rights place), but now it's basically assuming I have a US keyboard.

Is there anything I can do about this?

Edit: This is on Windows XP Pro SP2
Title: Re: UK Keyboards
Post by: elias on July 29, 2007, 18:41:43
I have a Danish keyboard, but if I go to the win xp International settings and select the UK layout, the LWJGL KeyboardTest seems to place at least @ and ` correctly, according to http://en.wikipedia.org/wiki/Keyboard_layout (The dos box doesn't show £ properly, because of code page issues). I assume the correct keyboard layout is selected?

- elias
Title: Re: UK Keyboards
Post by: HappyCat on July 29, 2007, 19:34:28
Yeah, keyboard is definetely set as UK. And things aren't quite as I originally thought. Keyboard.getEventCharacter() actually returns the correct characters for all keys as far as I can see.

However the following keys no longer seem to respond to either Keyboard.isKeyDown() or Keyboard.getEventKey():

the `/¬ key    (which used to respond as Keyboard.KEY_GRAVE - the '/@ key now responds as Keyboard.KEY_GRAVE)
the =/+ key    (which used to respond as Keyboard.KEY_EQUALS)
the SysRq key

Alan
Title: Re: UK Keyboards
Post by: elias on July 29, 2007, 19:55:34
All three keys should now be properly mapped in the UK layout.

- elias
Title: Re: UK Keyboards
Post by: HappyCat on July 29, 2007, 20:34:37
Cool - thanks.

I assume you mean in the next version.