Fix names for some wxSTC constants
Generally, Scintilla constants which names beginning with 'SCXX' are mapped to wxSTC names by by stripping out the 'SC' before prepending 'wxSTC_', for example SCWS_INVISIBLE gets mapped to wxSTC_WS_INVISIBLE. Unfortunately, this common rule of mapping the names is not applied to the (legacy) names beginning with 'SCVS_' and 'SCMOD_'. For the sake of consistency, also these names should conform to the common naming convention, so gen_iface.py is updated to generate conformant names for all affected prefixes. Legacy names are preserved for backward compatibility but commented deprecated and no longer referenced in the documentation. Closes #17808.
This commit is contained in:
parent
217941e9c3
commit
ee609de199
@ -367,10 +367,10 @@ class WXDLLIMPEXP_FWD_CORE wxScrollBar;
|
||||
#define wxSTC_ANNOTATION_BOXED 2
|
||||
#define wxSTC_ANNOTATION_INDENTED 3
|
||||
#define wxSTC_UNDO_MAY_COALESCE 1
|
||||
#define wxSTC_SCVS_NONE 0
|
||||
#define wxSTC_SCVS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_SCVS_USERACCESSIBLE 2
|
||||
#define wxSTC_SCVS_NOWRAPLINESTART 4
|
||||
#define wxSTC_VS_NONE 0
|
||||
#define wxSTC_VS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_VS_USERACCESSIBLE 2
|
||||
#define wxSTC_VS_NOWRAPLINESTART 4
|
||||
#define wxSTC_TECHNOLOGY_DEFAULT 0
|
||||
#define wxSTC_TECHNOLOGY_DIRECTWRITE 1
|
||||
#define wxSTC_TECHNOLOGY_DIRECTWRITERETAIN 2
|
||||
@ -443,12 +443,12 @@ class WXDLLIMPEXP_FWD_CORE wxScrollBar;
|
||||
#define wxSTC_KEY_WIN 313
|
||||
#define wxSTC_KEY_RWIN 314
|
||||
#define wxSTC_KEY_MENU 315
|
||||
#define wxSTC_SCMOD_NORM 0
|
||||
#define wxSTC_SCMOD_SHIFT 1
|
||||
#define wxSTC_SCMOD_CTRL 2
|
||||
#define wxSTC_SCMOD_ALT 4
|
||||
#define wxSTC_SCMOD_SUPER 8
|
||||
#define wxSTC_SCMOD_META 16
|
||||
#define wxSTC_KEYMOD_NORM 0
|
||||
#define wxSTC_KEYMOD_SHIFT 1
|
||||
#define wxSTC_KEYMOD_CTRL 2
|
||||
#define wxSTC_KEYMOD_ALT 4
|
||||
#define wxSTC_KEYMOD_SUPER 8
|
||||
#define wxSTC_KEYMOD_META 16
|
||||
#define wxSTC_AC_FILLUP 1
|
||||
#define wxSTC_AC_DOUBLECLICK 2
|
||||
#define wxSTC_AC_TAB 3
|
||||
@ -2472,6 +2472,23 @@ class WXDLLIMPEXP_FWD_CORE wxScrollBar;
|
||||
|
||||
//}}}
|
||||
//----------------------------------------------------------------------
|
||||
// The following entries have non-conformant prefixes. Although preserved
|
||||
// here for backwards compatibility, these should be considered deprecated.
|
||||
|
||||
// Instead of the following, use the wxSTC_KEYMOD_* entries defined above
|
||||
#define wxSTC_SCMOD_NORM 0
|
||||
#define wxSTC_SCMOD_SHIFT 1
|
||||
#define wxSTC_SCMOD_CTRL 2
|
||||
#define wxSTC_SCMOD_ALT 4
|
||||
#define wxSTC_SCMOD_SUPER 8
|
||||
#define wxSTC_SCMOD_META 16
|
||||
|
||||
// Instead of the following, use the wxSTC_VS_* entries defined above
|
||||
#define wxSTC_SCVS_NONE 0
|
||||
#define wxSTC_SCVS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_SCVS_USERACCESSIBLE 2
|
||||
#define wxSTC_SCVS_NOWRAPLINESTART 4
|
||||
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// Commands that can be bound to keystrokes section {{{
|
||||
|
@ -323,10 +323,10 @@
|
||||
#define wxSTC_ANNOTATION_BOXED 2
|
||||
#define wxSTC_ANNOTATION_INDENTED 3
|
||||
#define wxSTC_UNDO_MAY_COALESCE 1
|
||||
#define wxSTC_SCVS_NONE 0
|
||||
#define wxSTC_SCVS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_SCVS_USERACCESSIBLE 2
|
||||
#define wxSTC_SCVS_NOWRAPLINESTART 4
|
||||
#define wxSTC_VS_NONE 0
|
||||
#define wxSTC_VS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_VS_USERACCESSIBLE 2
|
||||
#define wxSTC_VS_NOWRAPLINESTART 4
|
||||
#define wxSTC_TECHNOLOGY_DEFAULT 0
|
||||
#define wxSTC_TECHNOLOGY_DIRECTWRITE 1
|
||||
#define wxSTC_TECHNOLOGY_DIRECTWRITERETAIN 2
|
||||
@ -399,12 +399,12 @@
|
||||
#define wxSTC_KEY_WIN 313
|
||||
#define wxSTC_KEY_RWIN 314
|
||||
#define wxSTC_KEY_MENU 315
|
||||
#define wxSTC_SCMOD_NORM 0
|
||||
#define wxSTC_SCMOD_SHIFT 1
|
||||
#define wxSTC_SCMOD_CTRL 2
|
||||
#define wxSTC_SCMOD_ALT 4
|
||||
#define wxSTC_SCMOD_SUPER 8
|
||||
#define wxSTC_SCMOD_META 16
|
||||
#define wxSTC_KEYMOD_NORM 0
|
||||
#define wxSTC_KEYMOD_SHIFT 1
|
||||
#define wxSTC_KEYMOD_CTRL 2
|
||||
#define wxSTC_KEYMOD_ALT 4
|
||||
#define wxSTC_KEYMOD_SUPER 8
|
||||
#define wxSTC_KEYMOD_META 16
|
||||
#define wxSTC_AC_FILLUP 1
|
||||
#define wxSTC_AC_DOUBLECLICK 2
|
||||
#define wxSTC_AC_TAB 3
|
||||
@ -7748,14 +7748,14 @@ public:
|
||||
The returned value is a bit list that may contain one or more of the
|
||||
following values:
|
||||
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_SHIFT wxSTC_SCMOD_SHIFT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_CTRL wxSTC_SCMOD_CTRL @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_ALT wxSTC_SCMOD_ALT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_SUPER wxSTC_SCMOD_SUPER @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_META wxSTC_SCMOD_META @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_SHIFT wxSTC_KEYMOD_SHIFT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_CTRL wxSTC_KEYMOD_CTRL @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_ALT wxSTC_KEYMOD_ALT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_SUPER wxSTC_KEYMOD_SUPER @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_META wxSTC_KEYMOD_META @endlink
|
||||
|
||||
In addition, the value can be checked for equality with @link
|
||||
wxStyledTextEvent::wxSTC_SCMOD_NORM wxSTC_SCMOD_NORM @endlink to test
|
||||
wxStyledTextEvent::wxSTC_KEYMOD_NORM wxSTC_KEYMOD_NORM @endlink to test
|
||||
if no modifiers are present.
|
||||
|
||||
This method is valid for the following event types:
|
||||
|
@ -41,6 +41,8 @@ valPrefixes = [('SCI_', ''),
|
||||
('SCFIND_', 'FIND_'),
|
||||
('SCWS_', 'WS_'),
|
||||
('SCTD_', 'TD_'),
|
||||
('SCVS_', 'VS_'),
|
||||
('SCMOD_', 'KEYMOD_'),
|
||||
]
|
||||
|
||||
# Message function values that should have a CMD_ constant generated
|
||||
|
@ -62,6 +62,23 @@ class WXDLLIMPEXP_FWD_CORE wxScrollBar;
|
||||
|
||||
//}}}
|
||||
//----------------------------------------------------------------------
|
||||
// The following entries have non-conformant prefixes. Although preserved
|
||||
// here for backwards compatibility, these should be considered deprecated.
|
||||
|
||||
// Instead of the following, use the wxSTC_KEYMOD_* entries defined above
|
||||
#define wxSTC_SCMOD_NORM 0
|
||||
#define wxSTC_SCMOD_SHIFT 1
|
||||
#define wxSTC_SCMOD_CTRL 2
|
||||
#define wxSTC_SCMOD_ALT 4
|
||||
#define wxSTC_SCMOD_SUPER 8
|
||||
#define wxSTC_SCMOD_META 16
|
||||
|
||||
// Instead of the following, use the wxSTC_VS_* entries defined above
|
||||
#define wxSTC_SCVS_NONE 0
|
||||
#define wxSTC_SCVS_RECTANGULARSELECTION 1
|
||||
#define wxSTC_SCVS_USERACCESSIBLE 2
|
||||
#define wxSTC_SCVS_NOWRAPLINESTART 4
|
||||
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
// Commands that can be bound to keystrokes section {{{
|
||||
|
@ -1513,14 +1513,14 @@ public:
|
||||
The returned value is a bit list that may contain one or more of the
|
||||
following values:
|
||||
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_SHIFT wxSTC_SCMOD_SHIFT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_CTRL wxSTC_SCMOD_CTRL @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_ALT wxSTC_SCMOD_ALT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_SUPER wxSTC_SCMOD_SUPER @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_SCMOD_META wxSTC_SCMOD_META @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_SHIFT wxSTC_KEYMOD_SHIFT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_CTRL wxSTC_KEYMOD_CTRL @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_ALT wxSTC_KEYMOD_ALT @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_SUPER wxSTC_KEYMOD_SUPER @endlink
|
||||
- @link wxStyledTextEvent::wxSTC_KEYMOD_META wxSTC_KEYMOD_META @endlink
|
||||
|
||||
In addition, the value can be checked for equality with @link
|
||||
wxStyledTextEvent::wxSTC_SCMOD_NORM wxSTC_SCMOD_NORM @endlink to test
|
||||
wxStyledTextEvent::wxSTC_KEYMOD_NORM wxSTC_KEYMOD_NORM @endlink to test
|
||||
if no modifiers are present.
|
||||
|
||||
This method is valid for the following event types:
|
||||
|
Loading…
Reference in New Issue
Block a user