]> git.saurik.com Git - wxWidgets.git/commitdiff
Add WXK_CONTROL_A..WXK_CONTROL_Z constants.
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 23 Mar 2011 12:59:59 +0000 (12:59 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 23 Mar 2011 12:59:59 +0000 (12:59 +0000)
These key codes provide nicer symbolic values for ASCII values in 1..26 range
generated by Ctrl+Letter keys.

Closes #13075.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67294 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/changes.txt
include/wx/defs.h
interface/wx/event.h

index cfaa93a461a44121e41da4e2469b3307418711ec..a2da01c5cede96c47d9ff63e4bacdd279aadb441 100644 (file)
@@ -495,6 +495,7 @@ All (GUI):
 - Added support for reading image resolutions from PNG images (scottb).
 - wxComboCtrl, wxOwnerDrawnComboBox: better support for themed and custom
   panel backgrounds, especially on OS X.
+- Add WXK_CONTROL_A..WXK_CONTROL_Z constants (Jan van Dijk).
 
 GTK:
 
index 6130fae99bfc99fc6a883c10d77972590a894008..68e9dad5f7888d3d2f82f329176b5fa21242bf0c 100644 (file)
@@ -2354,6 +2354,33 @@ enum wxKeyCode
 {
     WXK_NONE    =    0,
 
+    WXK_CONTROL_A = 1,
+    WXK_CONTROL_B,
+    WXK_CONTROL_C,
+    WXK_CONTROL_D,
+    WXK_CONTROL_E,
+    WXK_CONTROL_F,
+    WXK_CONTROL_G,
+    WXK_CONTROL_H,
+    WXK_CONTROL_I,
+    WXK_CONTROL_J,
+    WXK_CONTROL_K,
+    WXK_CONTROL_L,
+    WXK_CONTROL_M,
+    WXK_CONTROL_N,
+    WXK_CONTROL_O,
+    WXK_CONTROL_P,
+    WXK_CONTROL_Q,
+    WXK_CONTROL_R,
+    WXK_CONTROL_S,
+    WXK_CONTROL_T,
+    WXK_CONTROL_U,
+    WXK_CONTROL_V,
+    WXK_CONTROL_W,
+    WXK_CONTROL_X,
+    WXK_CONTROL_Y,
+    WXK_CONTROL_Z,
+
     WXK_BACK    =    8, // backspace
     WXK_TAB     =    9,
     WXK_RETURN  =    13,
index 24e6942a95ebe21e30005504b885a20856fda045..a3d00229787b10b0d0d026abc754deda3433e30e 100644 (file)
@@ -1252,6 +1252,8 @@ enum wxKeyCategoryFlags
     Notice that currently no translation is done for the presses of @c [, @c
     \\, @c ], @c ^ and @c _ keys which might be mapped to ASCII values from 27
     to 31.
+    Since version 2.9.2, the enum values @c WXK_CONTROL_A - @c WXK_CONTROL_Z
+    can be used instead of the non-descriptive constant values 1-26.
 
     Finally, modifier keys only generate key events but no char events at all.
     The modifiers keys are @c WXK_SHIFT, @c WXK_CONTROL, @c WXK_ALT and various