Issue #1 new

Unable to simulate AltGr key

Anonymous created an issue

Hi, SendKeys can be used to send Left and Right Alt, but when used under UK Extended Keyboard Layout (for example French Input), Right Alt does not behave like AltGr key.

Here's how to reproduce the problem: in WinXP, from 'Text services and Input languages' add French (France), 'United Kingdom Extended'.

open WordPad, using this input method LControl + LAlt + E will produce a €, euro symbol. LControl + RAlt + E will produce a é, accented e. RAlt + E will produce a é. (that's because RAlt = LControl + RAlt)

with SendKeys, (165 is virtual keycode of RAlt)

key_down(165) SendKeys('e', turn_off_numlock = False) key_up(165)

produces a €, euro symbol, as if the system cannot tell the difference between RAlt and LAlft.

Suggested fix: I believe in _sendkeys.c you need add KEYEVENTF_EXTENDEDKEY when you use keybd_event to create an RAlt event

Could you fix it for me? I'm not C expert.

Comments (0)

  1. Log in to comment