📄 stc.h
字号:
////////////////////////////////////////////////////////////////////////////// Name: stc.h// Purpose: A wxWidgets implementation of Scintilla. This class is the// one meant to be used directly by wx applications. It does not// derive directly from the Scintilla classes, and in fact there// is no mention of Scintilla classes at all in this header.// This class delegates all method calls and events to the// Scintilla objects and so forth. This allows the use of// Scintilla without polluting the namespace with all the// classes and itentifiers from Scintilla.//// Author: Robin Dunn//// Created: 13-Jan-2000// RCS-ID: $Id: stc.h,v 1.74 2006/08/31 05:35:26 RD Exp $// Copyright: (c) 2000 by Total Control Software// Licence: wxWindows license/////////////////////////////////////////////////////////////////////////////#ifndef __stc_h__#define __stc_h__#include "wx/wx.h"#include "wx/dnd.h"#ifdef WXMAKINGDLL_STC #define WXDLLIMPEXP_STC WXEXPORT#elif defined(WXUSINGDLL) #define WXDLLIMPEXP_STC WXIMPORT#else // not making nor using DLL #define WXDLLIMPEXP_STC#endif// SWIG can't handle "#if" type of conditionals, only "#ifdef"#ifdef SWIG#define STC_USE_DND 1#else#if wxUSE_DRAG_AND_DROP#define STC_USE_DND 1#endif#endif//----------------------------------------------------------------------// Should a wxPopupWindow be used for the call tips and autocomplete windows?#ifndef wxSTC_USE_POPUP#define wxSTC_USE_POPUP 1#endif//----------------------------------------------------------------------// BEGIN generated section. The following code is automatically generated// by gen_iface.py. Do not edit this file. Edit stc.h.in instead// and regenerate#define wxSTC_INVALID_POSITION -1// Define start of Scintilla messages to be greater than all Windows edit (EM_*) messages// as many EM_ messages can be used although that use is deprecated.#define wxSTC_START 2000#define wxSTC_OPTIONAL_START 3000#define wxSTC_LEXER_START 4000#define wxSTC_WS_INVISIBLE 0#define wxSTC_WS_VISIBLEALWAYS 1#define wxSTC_WS_VISIBLEAFTERINDENT 2#define wxSTC_EOL_CRLF 0#define wxSTC_EOL_CR 1#define wxSTC_EOL_LF 2// The SC_CP_UTF8 value can be used to enter Unicode mode.// This is the same value as CP_UTF8 in Windows#define wxSTC_CP_UTF8 65001// The SC_CP_DBCS value can be used to indicate a DBCS mode for GTK+.#define wxSTC_CP_DBCS 1#define wxSTC_MARKER_MAX 31#define wxSTC_MARK_CIRCLE 0#define wxSTC_MARK_ROUNDRECT 1#define wxSTC_MARK_ARROW 2#define wxSTC_MARK_SMALLRECT 3#define wxSTC_MARK_SHORTARROW 4#define wxSTC_MARK_EMPTY 5#define wxSTC_MARK_ARROWDOWN 6#define wxSTC_MARK_MINUS 7#define wxSTC_MARK_PLUS 8// Shapes used for outlining column.#define wxSTC_MARK_VLINE 9#define wxSTC_MARK_LCORNER 10#define wxSTC_MARK_TCORNER 11#define wxSTC_MARK_BOXPLUS 12#define wxSTC_MARK_BOXPLUSCONNECTED 13#define wxSTC_MARK_BOXMINUS 14#define wxSTC_MARK_BOXMINUSCONNECTED 15#define wxSTC_MARK_LCORNERCURVE 16#define wxSTC_MARK_TCORNERCURVE 17#define wxSTC_MARK_CIRCLEPLUS 18#define wxSTC_MARK_CIRCLEPLUSCONNECTED 19#define wxSTC_MARK_CIRCLEMINUS 20#define wxSTC_MARK_CIRCLEMINUSCONNECTED 21// Invisible mark that only sets the line background color.#define wxSTC_MARK_BACKGROUND 22#define wxSTC_MARK_DOTDOTDOT 23#define wxSTC_MARK_ARROWS 24#define wxSTC_MARK_PIXMAP 25#define wxSTC_MARK_FULLRECT 26#define wxSTC_MARK_CHARACTER 10000// Markers used for outlining column.#define wxSTC_MARKNUM_FOLDEREND 25#define wxSTC_MARKNUM_FOLDEROPENMID 26#define wxSTC_MARKNUM_FOLDERMIDTAIL 27#define wxSTC_MARKNUM_FOLDERTAIL 28#define wxSTC_MARKNUM_FOLDERSUB 29#define wxSTC_MARKNUM_FOLDER 30#define wxSTC_MARKNUM_FOLDEROPEN 31#define wxSTC_MASK_FOLDERS 0xFE000000#define wxSTC_MARGIN_SYMBOL 0#define wxSTC_MARGIN_NUMBER 1#define wxSTC_MARGIN_BACK 2#define wxSTC_MARGIN_FORE 3// Styles in range 32..38 are predefined for parts of the UI and are not used as normal styles.// Style 39 is for future use.#define wxSTC_STYLE_DEFAULT 32#define wxSTC_STYLE_LINENUMBER 33#define wxSTC_STYLE_BRACELIGHT 34#define wxSTC_STYLE_BRACEBAD 35#define wxSTC_STYLE_CONTROLCHAR 36#define wxSTC_STYLE_INDENTGUIDE 37#define wxSTC_STYLE_CALLTIP 38#define wxSTC_STYLE_LASTPREDEFINED 39#define wxSTC_STYLE_MAX 127// Character set identifiers are used in StyleSetCharacterSet.// The values are the same as the Windows *_CHARSET values.#define wxSTC_CHARSET_ANSI 0#define wxSTC_CHARSET_DEFAULT 1#define wxSTC_CHARSET_BALTIC 186#define wxSTC_CHARSET_CHINESEBIG5 136#define wxSTC_CHARSET_EASTEUROPE 238#define wxSTC_CHARSET_GB2312 134#define wxSTC_CHARSET_GREEK 161#define wxSTC_CHARSET_HANGUL 129#define wxSTC_CHARSET_MAC 77#define wxSTC_CHARSET_OEM 255#define wxSTC_CHARSET_RUSSIAN 204#define wxSTC_CHARSET_CYRILLIC 1251#define wxSTC_CHARSET_SHIFTJIS 128#define wxSTC_CHARSET_SYMBOL 2#define wxSTC_CHARSET_TURKISH 162#define wxSTC_CHARSET_JOHAB 130#define wxSTC_CHARSET_HEBREW 177#define wxSTC_CHARSET_ARABIC 178#define wxSTC_CHARSET_VIETNAMESE 163#define wxSTC_CHARSET_THAI 222#define wxSTC_CHARSET_8859_15 1000#define wxSTC_CASE_MIXED 0#define wxSTC_CASE_UPPER 1#define wxSTC_CASE_LOWER 2#define wxSTC_INDIC_MAX 7#define wxSTC_INDIC_PLAIN 0#define wxSTC_INDIC_SQUIGGLE 1#define wxSTC_INDIC_TT 2#define wxSTC_INDIC_DIAGONAL 3#define wxSTC_INDIC_STRIKE 4#define wxSTC_INDIC_HIDDEN 5#define wxSTC_INDIC_BOX 6#define wxSTC_INDIC_ROUNDBOX 7#define wxSTC_INDIC0_MASK 0x20#define wxSTC_INDIC1_MASK 0x40#define wxSTC_INDIC2_MASK 0x80#define wxSTC_INDICS_MASK 0xE0// PrintColourMode - use same colours as screen.#define wxSTC_PRINT_NORMAL 0// PrintColourMode - invert the light value of each style for printing.#define wxSTC_PRINT_INVERTLIGHT 1// PrintColourMode - force black text on white background for printing.#define wxSTC_PRINT_BLACKONWHITE 2// PrintColourMode - text stays coloured, but all background is forced to be white for printing.#define wxSTC_PRINT_COLOURONWHITE 3// PrintColourMode - only the default-background is forced to be white for printing.#define wxSTC_PRINT_COLOURONWHITEDEFAULTBG 4#define wxSTC_FIND_WHOLEWORD 2#define wxSTC_FIND_MATCHCASE 4#define wxSTC_FIND_WORDSTART 0x00100000#define wxSTC_FIND_REGEXP 0x00200000#define wxSTC_FIND_POSIX 0x00400000#define wxSTC_FOLDLEVELBASE 0x400#define wxSTC_FOLDLEVELWHITEFLAG 0x1000#define wxSTC_FOLDLEVELHEADERFLAG 0x2000#define wxSTC_FOLDLEVELBOXHEADERFLAG 0x4000#define wxSTC_FOLDLEVELBOXFOOTERFLAG 0x8000#define wxSTC_FOLDLEVELCONTRACTED 0x10000#define wxSTC_FOLDLEVELUNINDENT 0x20000#define wxSTC_FOLDLEVELNUMBERMASK 0x0FFF#define wxSTC_FOLDFLAG_LINEBEFORE_EXPANDED 0x0002#define wxSTC_FOLDFLAG_LINEBEFORE_CONTRACTED 0x0004#define wxSTC_FOLDFLAG_LINEAFTER_EXPANDED 0x0008#define wxSTC_FOLDFLAG_LINEAFTER_CONTRACTED 0x0010#define wxSTC_FOLDFLAG_LEVELNUMBERS 0x0040#define wxSTC_FOLDFLAG_BOX 0x0001#define wxSTC_TIME_FOREVER 10000000#define wxSTC_WRAP_NONE 0#define wxSTC_WRAP_WORD 1#define wxSTC_WRAP_CHAR 2#define wxSTC_WRAPVISUALFLAG_NONE 0x0000#define wxSTC_WRAPVISUALFLAG_END 0x0001#define wxSTC_WRAPVISUALFLAG_START 0x0002#define wxSTC_WRAPVISUALFLAGLOC_DEFAULT 0x0000#define wxSTC_WRAPVISUALFLAGLOC_END_BY_TEXT 0x0001#define wxSTC_WRAPVISUALFLAGLOC_START_BY_TEXT 0x0002#define wxSTC_CACHE_NONE 0#define wxSTC_CACHE_CARET 1#define wxSTC_CACHE_PAGE 2#define wxSTC_CACHE_DOCUMENT 3#define wxSTC_EDGE_NONE 0#define wxSTC_EDGE_LINE 1#define wxSTC_EDGE_BACKGROUND 2#define wxSTC_CURSORNORMAL -1#define wxSTC_CURSORWAIT 4// Constants for use with SetVisiblePolicy, similar to SetCaretPolicy.#define wxSTC_VISIBLE_SLOP 0x01#define wxSTC_VISIBLE_STRICT 0x04// Caret policy, used by SetXCaretPolicy and SetYCaretPolicy.// If CARET_SLOP is set, we can define a slop value: caretSlop.// This value defines an unwanted zone (UZ) where the caret is... unwanted.// This zone is defined as a number of pixels near the vertical margins,// and as a number of lines near the horizontal margins.// By keeping the caret away from the edges, it is seen within its context,// so it is likely that the identifier that the caret is on can be completely seen,// and that the current line is seen with some of the lines following it which are// often dependent on that line.#define wxSTC_CARET_SLOP 0x01// If CARET_STRICT is set, the policy is enforced... strictly.// The caret is centred on the display if slop is not set,// and cannot go in the UZ if slop is set.#define wxSTC_CARET_STRICT 0x04// If CARET_JUMPS is set, the display is moved more energetically// so the caret can move in the same direction longer before the policy is applied again.#define wxSTC_CARET_JUMPS 0x10// If CARET_EVEN is not set, instead of having symmetrical UZs,// the left and bottom UZs are extended up to right and top UZs respectively.// This way, we favour the displaying of useful information: the begining of lines,// where most code reside, and the lines after the caret, eg. the body of a function.#define wxSTC_CARET_EVEN 0x08// Selection modes#define wxSTC_SEL_STREAM 0#define wxSTC_SEL_RECTANGLE 1#define wxSTC_SEL_LINES 2#define wxSTC_ALPHA_TRANSPARENT 0#define wxSTC_ALPHA_OPAQUE 255#define wxSTC_ALPHA_NOALPHA 256// Maximum value of keywordSet parameter of SetKeyWords.#define wxSTC_KEYWORDSET_MAX 8// Notifications// Type of modification and the action which caused the modification.// These are defined as a bit mask to make it easy to specify which notifications are wanted.// One bit is set from each of SC_MOD_* and SC_PERFORMED_*.#define wxSTC_MOD_INSERTTEXT 0x1#define wxSTC_MOD_DELETETEXT 0x2#define wxSTC_MOD_CHANGESTYLE 0x4#define wxSTC_MOD_CHANGEFOLD 0x8#define wxSTC_PERFORMED_USER 0x10#define wxSTC_PERFORMED_UNDO 0x20#define wxSTC_PERFORMED_REDO 0x40#define wxSTC_MULTISTEPUNDOREDO 0x80#define wxSTC_LASTSTEPINUNDOREDO 0x100#define wxSTC_MOD_CHANGEMARKER 0x200#define wxSTC_MOD_BEFOREINSERT 0x400#define wxSTC_MOD_BEFOREDELETE 0x800#define wxSTC_MULTILINEUNDOREDO 0x1000#define wxSTC_MODEVENTMASKALL 0x1FFF// Symbolic key codes and modifier flags.// ASCII and other printable characters below 256.// Extended keys above 300.#define wxSTC_KEY_DOWN 300#define wxSTC_KEY_UP 301#define wxSTC_KEY_LEFT 302#define wxSTC_KEY_RIGHT 303#define wxSTC_KEY_HOME 304#define wxSTC_KEY_END 305#define wxSTC_KEY_PRIOR 306#define wxSTC_KEY_NEXT 307#define wxSTC_KEY_DELETE 308#define wxSTC_KEY_INSERT 309#define wxSTC_KEY_ESCAPE 7#define wxSTC_KEY_BACK 8#define wxSTC_KEY_TAB 9#define wxSTC_KEY_RETURN 13#define wxSTC_KEY_ADD 310#define wxSTC_KEY_SUBTRACT 311#define wxSTC_KEY_DIVIDE 312#define wxSTC_SCMOD_NORM 0#define wxSTC_SCMOD_SHIFT 1#define wxSTC_SCMOD_CTRL 2#define wxSTC_SCMOD_ALT 4// For SciLexer.h#define wxSTC_LEX_CONTAINER 0#define wxSTC_LEX_NULL 1#define wxSTC_LEX_PYTHON 2#define wxSTC_LEX_CPP 3#define wxSTC_LEX_HTML 4#define wxSTC_LEX_XML 5#define wxSTC_LEX_PERL 6#define wxSTC_LEX_SQL 7#define wxSTC_LEX_VB 8#define wxSTC_LEX_PROPERTIES 9#define wxSTC_LEX_ERRORLIST 10#define wxSTC_LEX_MAKEFILE 11#define wxSTC_LEX_BATCH 12#define wxSTC_LEX_XCODE 13#define wxSTC_LEX_LATEX 14#define wxSTC_LEX_LUA 15#define wxSTC_LEX_DIFF 16#define wxSTC_LEX_CONF 17#define wxSTC_LEX_PASCAL 18#define wxSTC_LEX_AVE 19#define wxSTC_LEX_ADA 20#define wxSTC_LEX_LISP 21#define wxSTC_LEX_RUBY 22#define wxSTC_LEX_EIFFEL 23#define wxSTC_LEX_EIFFELKW 24#define wxSTC_LEX_TCL 25#define wxSTC_LEX_NNCRONTAB 26#define wxSTC_LEX_BULLANT 27#define wxSTC_LEX_VBSCRIPT 28#define wxSTC_LEX_BAAN 31#define wxSTC_LEX_MATLAB 32#define wxSTC_LEX_SCRIPTOL 33#define wxSTC_LEX_ASM 34#define wxSTC_LEX_CPPNOCASE 35#define wxSTC_LEX_FORTRAN 36#define wxSTC_LEX_F77 37#define wxSTC_LEX_CSS 38#define wxSTC_LEX_POV 39#define wxSTC_LEX_LOUT 40#define wxSTC_LEX_ESCRIPT 41#define wxSTC_LEX_PS 42#define wxSTC_LEX_NSIS 43#define wxSTC_LEX_MMIXAL 44#define wxSTC_LEX_CLW 45#define wxSTC_LEX_CLWNOCASE 46#define wxSTC_LEX_LOT 47#define wxSTC_LEX_YAML 48#define wxSTC_LEX_TEX 49#define wxSTC_LEX_METAPOST 50#define wxSTC_LEX_POWERBASIC 51#define wxSTC_LEX_FORTH 52#define wxSTC_LEX_ERLANG 53#define wxSTC_LEX_OCTAVE 54#define wxSTC_LEX_MSSQL 55#define wxSTC_LEX_VERILOG 56#define wxSTC_LEX_KIX 57#define wxSTC_LEX_GUI4CLI 58#define wxSTC_LEX_SPECMAN 59#define wxSTC_LEX_AU3 60#define wxSTC_LEX_APDL 61#define wxSTC_LEX_BASH 62#define wxSTC_LEX_ASN1 63#define wxSTC_LEX_VHDL 64#define wxSTC_LEX_CAML 65#define wxSTC_LEX_BLITZBASIC 66#define wxSTC_LEX_PUREBASIC 67#define wxSTC_LEX_HASKELL 68#define wxSTC_LEX_PHPSCRIPT 69#define wxSTC_LEX_TADS3 70#define wxSTC_LEX_REBOL 71#define wxSTC_LEX_SMALLTALK 72#define wxSTC_LEX_FLAGSHIP 73#define wxSTC_LEX_CSOUND 74#define wxSTC_LEX_FREEBASIC 75#define wxSTC_LEX_INNOSETUP 76#define wxSTC_LEX_OPAL 77#define wxSTC_LEX_SPICE 78// When a lexer specifies its language as SCLEX_AUTOMATIC it receives a// value assigned in sequence from SCLEX_AUTOMATIC+1.#define wxSTC_LEX_AUTOMATIC 1000// Lexical states for SCLEX_PYTHON#define wxSTC_P_DEFAULT 0#define wxSTC_P_COMMENTLINE 1#define wxSTC_P_NUMBER 2#define wxSTC_P_STRING 3#define wxSTC_P_CHARACTER 4#define wxSTC_P_WORD 5#define wxSTC_P_TRIPLE 6#define wxSTC_P_TRIPLEDOUBLE 7#define wxSTC_P_CLASSNAME 8#define wxSTC_P_DEFNAME 9#define wxSTC_P_OPERATOR 10#define wxSTC_P_IDENTIFIER 11#define wxSTC_P_COMMENTBLOCK 12#define wxSTC_P_STRINGEOL 13#define wxSTC_P_WORD2 14#define wxSTC_P_DECORATOR 15// Lexical states for SCLEX_CPP#define wxSTC_C_DEFAULT 0#define wxSTC_C_COMMENT 1#define wxSTC_C_COMMENTLINE 2#define wxSTC_C_COMMENTDOC 3#define wxSTC_C_NUMBER 4#define wxSTC_C_WORD 5#define wxSTC_C_STRING 6#define wxSTC_C_CHARACTER 7#define wxSTC_C_UUID 8#define wxSTC_C_PREPROCESSOR 9
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -