X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ae3c17b4013e80b99976c750c19fca47729517f6..c29c95fe24973b94fd724db767193171ca7c513d:/interface/wx/accel.h
diff --git a/interface/wx/accel.h b/interface/wx/accel.h
index 616f2b047a..974731fab6 100644
--- a/interface/wx/accel.h
+++ b/interface/wx/accel.h
@@ -3,7 +3,7 @@
// Purpose: interface of wxAccelerator* classes
// Author: wxWidgets team
// RCS-ID: $Id$
-// Licence: wxWindows license
+// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
@@ -29,13 +29,12 @@ enum wxAcceleratorEntryFlags
/**
@class wxAcceleratorEntry
- @wxheader{accel.h}
An object used by an application wishing to create an accelerator table
(see wxAcceleratorTable).
@library{wxcore}
- @category{misc}
+ @category{data}
@see wxAcceleratorTable, wxWindow::SetAcceleratorTable
*/
@@ -46,10 +45,10 @@ public:
Constructor.
@param flags
- A combination of the wxAcceleratorEntryFlags values, which
+ A combination of the ::wxAcceleratorEntryFlags values, which
indicates which modifier keys are held down.
@param keyCode
- The keycode to be detected. See @ref page_keycodes for a full list of keycodes.
+ The keycode to be detected. See ::wxKeyCode for a full list of keycodes.
@param cmd
The menu or control command identifier (ID).
@param item
@@ -87,10 +86,10 @@ public:
Sets the accelerator entry parameters.
@param flags
- A combination of the wxAcceleratorEntryFlags values, which
+ A combination of the ::wxAcceleratorEntryFlags values, which
indicates which modifier keys are held down.
@param keyCode
- The keycode to be detected. See @ref page_keycodes for a full list of keycodes.
+ The keycode to be detected. See ::wxKeyCode for a full list of keycodes.
@param cmd
The menu or control command identifier (ID).
@param item
@@ -104,9 +103,11 @@ public:
bool IsOk() const;
/**
- Returns a wxString for this accelerator.
- This function formats it using the @c "flags-keycode" format
- where @c flags maybe a hyphen-separed list of @c "shift|alt|ctrl".
+ Returns a textual representation of this accelerator.
+
+ The returned string is of the form [Alt+][Ctrl+][Shift+]Key
+ where the modifier keys are present only if the corresponding flag is
+ set.
*/
wxString ToString() const;
@@ -114,7 +115,14 @@ public:
Parses the given string and sets the accelerator accordingly.
@param str
- Should be a string in the form "flags-keycode"
+ This string may be either in the same format as returned by
+ ToString(), i.e. contain the accelerator itself only, or have the
+ format of a full menu item text with i.e. Label TAB
+ Accelerator
. In the latter case, the part of the string
+ before the TAB is ignored. Notice that the latter format is only
+ supported for the compatibility with the previous wxWidgets
+ versions and the new code should pass only the accelerator string
+ itself to this function.
@return @true if the given string correctly initialized this object
(i.e. if IsOk() returns true after this call)
@@ -130,7 +138,6 @@ public:
/**
@class wxAcceleratorTable
- @wxheader{accel.h}
An accelerator table allows the application to specify a table of keyboard
shortcuts for menu or button commands.
@@ -158,7 +165,7 @@ public:
'OK'.
@library{wxcore}
- @category{misc}
+ @category{data}
@stdobjects
::wxNullAcceleratorTable
@@ -180,6 +187,13 @@ public:
Number of accelerator entries.
@param entries
The array of entries.
+
+ @beginWxPerlOnly
+ The wxPerl constructor accepts a list of either
+ Wx::AcceleratorEntry objects or references to 3-element arrays
+ [flags, keyCode, cmd] , like the parameters of
+ Wx::AcceleratorEntry::new.
+ @endWxPerlOnly
*/
wxAcceleratorTable(int n, const wxAcceleratorEntry entries[]);