From 98720ee7a45edab821a4175a54d8a4dd2494e7db Mon Sep 17 00:00:00 2001 From: New Pagodi Date: Thu, 23 Feb 2017 23:02:19 +0100 Subject: [PATCH] Fix names of newly introduced wxSTC constants In 68888ca0a2d53772122dd452958e14cf270431a1 there were introduced new wxSTC constants representing Scintilla SCTD_* parameters. Unfortunately, their names don't conform to naming convention of other constants and therefore should be changed. For the sake of consistency, Scintilla SCTD_* names should be mapped to wxSTC_TD_* ones. Closes #17807. --- include/wx/stc/stc.h | 4 ++-- interface/wx/stc/stc.h | 4 ++-- src/stc/gen_iface.py | 1 + src/stc/scintilla/README.txt | 4 +++- 4 files changed, 8 insertions(+), 5 deletions(-) diff --git a/include/wx/stc/stc.h b/include/wx/stc/stc.h index fd255c2f16..399cb81857 100644 --- a/include/wx/stc/stc.h +++ b/include/wx/stc/stc.h @@ -69,8 +69,8 @@ class WXDLLIMPEXP_FWD_CORE wxScrollBar; #define wxSTC_WS_VISIBLEALWAYS 1 #define wxSTC_WS_VISIBLEAFTERINDENT 2 #define wxSTC_WS_VISIBLEONLYININDENT 3 -#define wxSTC_SCTD_LONGARROW 0 -#define wxSTC_SCTD_STRIKEOUT 1 +#define wxSTC_TD_LONGARROW 0 +#define wxSTC_TD_STRIKEOUT 1 #define wxSTC_EOL_CRLF 0 #define wxSTC_EOL_CR 1 #define wxSTC_EOL_LF 2 diff --git a/interface/wx/stc/stc.h b/interface/wx/stc/stc.h index 1a6a15182c..4ecd5eb787 100644 --- a/interface/wx/stc/stc.h +++ b/interface/wx/stc/stc.h @@ -25,8 +25,8 @@ #define wxSTC_WS_VISIBLEALWAYS 1 #define wxSTC_WS_VISIBLEAFTERINDENT 2 #define wxSTC_WS_VISIBLEONLYININDENT 3 -#define wxSTC_SCTD_LONGARROW 0 -#define wxSTC_SCTD_STRIKEOUT 1 +#define wxSTC_TD_LONGARROW 0 +#define wxSTC_TD_STRIKEOUT 1 #define wxSTC_EOL_CRLF 0 #define wxSTC_EOL_CR 1 #define wxSTC_EOL_LF 2 diff --git a/src/stc/gen_iface.py b/src/stc/gen_iface.py index 9e7a6b9c49..e72f3e23a7 100755 --- a/src/stc/gen_iface.py +++ b/src/stc/gen_iface.py @@ -40,6 +40,7 @@ valPrefixes = [('SCI_', ''), ('SCK_', 'KEY_'), ('SCFIND_', 'FIND_'), ('SCWS_', 'WS_'), + ('SCTD_', 'TD_'), ] # Message function values that should have a CMD_ constant generated diff --git a/src/stc/scintilla/README.txt b/src/stc/scintilla/README.txt index 071178d25d..cea8c56395 100644 --- a/src/stc/scintilla/README.txt +++ b/src/stc/scintilla/README.txt @@ -42,7 +42,9 @@ Foreground and Background. If there is a new method that could be considered a "command function" (something that takes no parameters and could conceivably be bound to a key event) then I make sure that it's ID is in cmdValues or included in one of the existing ranges in -that list. +that list. Also, for any enums that begin with 'SCXX_' instead of +'SC_', add an entry to valPrefixes to make sure the new names for +constants are generated consistently. 7. Run gen_iface.py.