[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Bug reports
. . -> [Subject]  Accelerator VK_OEM_PLUS mapping is broken
Home  |  Users  |  Search  |  FAQ
Register forum user name
Forgotten password?

Accelerator VK_OEM_PLUS mapping is broken

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Posted by Worstje   Netherlands  (899 posts)  [Biography] bio
Date Sun 22 Apr 2012 10:56 AM (UTC)

Amended on Sun 22 Apr 2012 11:04 AM (UTC) by Worstje

I was trying to get an ALT+'PlusEquals' working... which is, the key ([=+]) to the left of backspace and to the right of [9(]. [0)] and [-_]. And I failed.

Since I could not figure out what key was doing it, I ended up searching the source and I believe I found a bug alongside the proper mapping name.

StringToKeyCode (Utilities.cpp) splits on the + character to separate different units. However, accelerators.cpp defines the VirtualKeyMapping VirtuakKeys as being: { VK_OEM_PLUS , "+" }

Which means the VK_OEM_PLUS keymapping never gets used. Testing as follows:

print(Accelerator("Alt++", "Pressed plusequals key"))

indeed returns eBadParameter - something that shouldn't happen as + is clearly a defined mapping!

May I suggest that this one is renamed to vk_oem_plus? It is likely easier than rewriting StringToKeyCode to properly support a plus in the mapping name.

Edit: while trying to figure out the proper virtual key code I had reports this key might have different virtual key codes on different keyboards, but I've not been able to test / confirm for myself. Is it possible for you to test if this key works properly after applying a fix?
[Go to top] top

Posted by Nick Gammon   Australia  (21,562 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Wed 25 Apr 2012 03:02 AM (UTC)
Worstje said:

May I suggest that this one is renamed to vk_oem_plus?

Changed to "Plus". Commit c386300.

It appears to work for me, but I am using an Mac aluminum keyboard through VMware. But, it works.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum

[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]