diff options
-rw-r--r-- | core/._SCINTILLA.luadoc | 290 | ||||
-rw-r--r-- | core/.buffer.luadoc | 262 | ||||
-rw-r--r-- | core/.view.luadoc | 4 | ||||
-rw-r--r-- | core/file_io.lua | 6 | ||||
-rw-r--r-- | core/iface.lua | 4 | ||||
-rw-r--r-- | core/ui.lua | 14 | ||||
-rw-r--r-- | doc/06_AdeptEditing.md | 2 | ||||
-rw-r--r-- | doc/14_Appendix.md | 4 | ||||
-rw-r--r-- | doc/markdowndoc.lua | 1 | ||||
-rw-r--r-- | modules/textadept/adeptsense.lua | 9 | ||||
-rw-r--r-- | modules/textadept/find.lua | 4 | ||||
-rw-r--r-- | modules/textadept/keys.lua | 6 | ||||
-rw-r--r-- | modules/textadept/menu.lua | 6 | ||||
-rw-r--r-- | modules/textadept/snippets.lua | 5 | ||||
-rw-r--r-- | properties.lua | 99 | ||||
-rwxr-xr-x | scripts/gen_iface.lua | 5 |
16 files changed, 349 insertions, 372 deletions
diff --git a/core/._SCINTILLA.luadoc b/core/._SCINTILLA.luadoc index ddf4e58d..8df0b680 100644 --- a/core/._SCINTILLA.luadoc +++ b/core/._SCINTILLA.luadoc @@ -38,26 +38,6 @@ -- * `_G._SCINTILLA.constants.SCFIND_REGEXP` 2097152 -- * `_G._SCINTILLA.constants.SCFIND_WHOLEWORD` 2 -- * `_G._SCINTILLA.constants.SCFIND_WORDSTART` 1048576 --- * `_G._SCINTILLA.constants.SCK_ADD` 310 --- * `_G._SCINTILLA.constants.SCK_BACK` 8 --- * `_G._SCINTILLA.constants.SCK_DELETE` 308 --- * `_G._SCINTILLA.constants.SCK_DIVIDE` 312 --- * `_G._SCINTILLA.constants.SCK_DOWN` 300 --- * `_G._SCINTILLA.constants.SCK_END` 305 --- * `_G._SCINTILLA.constants.SCK_ESCAPE` 7 --- * `_G._SCINTILLA.constants.SCK_HOME` 304 --- * `_G._SCINTILLA.constants.SCK_INSERT` 309 --- * `_G._SCINTILLA.constants.SCK_LEFT` 302 --- * `_G._SCINTILLA.constants.SCK_MENU` 315 --- * `_G._SCINTILLA.constants.SCK_NEXT` 307 --- * `_G._SCINTILLA.constants.SCK_PRIOR` 306 --- * `_G._SCINTILLA.constants.SCK_RETURN` 13 --- * `_G._SCINTILLA.constants.SCK_RIGHT` 303 --- * `_G._SCINTILLA.constants.SCK_RWIN` 314 --- * `_G._SCINTILLA.constants.SCK_SUBTRACT` 311 --- * `_G._SCINTILLA.constants.SCK_TAB` 9 --- * `_G._SCINTILLA.constants.SCK_UP` 301 --- * `_G._SCINTILLA.constants.SCK_WIN` 313 -- * `_G._SCINTILLA.constants.SCMOD_ALT` 4 -- * `_G._SCINTILLA.constants.SCMOD_CTRL` 2 -- * `_G._SCINTILLA.constants.SCMOD_META` 16 @@ -70,141 +50,141 @@ -- * `_G._SCINTILLA.constants.SCWS_INVISIBLE` 0 -- * `_G._SCINTILLA.constants.SCWS_VISIBLEAFTERINDENT` 2 -- * `_G._SCINTILLA.constants.SCWS_VISIBLEALWAYS` 1 --- * `_G._SCINTILLA.constants.SC_ALPHA_NOALPHA` 256 --- * `_G._SCINTILLA.constants.SC_ALPHA_OPAQUE` 255 --- * `_G._SCINTILLA.constants.SC_ALPHA_TRANSPARENT` 0 --- * `_G._SCINTILLA.constants.SC_AUTOMATICFOLD_CHANGE` 4 --- * `_G._SCINTILLA.constants.SC_AUTOMATICFOLD_CLICK` 2 --- * `_G._SCINTILLA.constants.SC_AUTOMATICFOLD_SHOW` 1 --- * `_G._SCINTILLA.constants.SC_CARETSTICKY_OFF` 0 --- * `_G._SCINTILLA.constants.SC_CARETSTICKY_ON` 1 --- * `_G._SCINTILLA.constants.SC_CARETSTICKY_WHITESPACE` 2 --- * `_G._SCINTILLA.constants.SC_CASEINSENSITIVEBEHAVIOUR_IGNORECASE` 1 --- * `_G._SCINTILLA.constants.SC_CASEINSENSITIVEBEHAVIOUR_RESPECTCASE` 0 --- * `_G._SCINTILLA.constants.SC_CASE_LOWER` 2 --- * `_G._SCINTILLA.constants.SC_CASE_MIXED` 0 --- * `_G._SCINTILLA.constants.SC_CASE_UPPER` 1 --- * `_G._SCINTILLA.constants.SC_CP_UTF8` 65001 --- * `_G._SCINTILLA.constants.SC_CURSORARROW` 2 --- * `_G._SCINTILLA.constants.SC_CURSORNORMAL` -1 --- * `_G._SCINTILLA.constants.SC_CURSORREVERSEARROW` 7 --- * `_G._SCINTILLA.constants.SC_CURSORWAIT` 4 --- * `_G._SCINTILLA.constants.SC_EOL_CR` 1 --- * `_G._SCINTILLA.constants.SC_EOL_CRLF` 0 --- * `_G._SCINTILLA.constants.SC_EOL_LF` 2 --- * `_G._SCINTILLA.constants.SC_FOLDACTION_CONTRACT` 0 --- * `_G._SCINTILLA.constants.SC_FOLDACTION_EXPAND` 1 --- * `_G._SCINTILLA.constants.SC_FOLDACTION_TOGGLE` 2 --- * `_G._SCINTILLA.constants.SC_FOLDFLAG_LEVELNUMBERS` 64 --- * `_G._SCINTILLA.constants.SC_FOLDFLAG_LINEAFTER_CONTRACTED` 16 --- * `_G._SCINTILLA.constants.SC_FOLDFLAG_LINEAFTER_EXPANDED` 8 --- * `_G._SCINTILLA.constants.SC_FOLDFLAG_LINEBEFORE_CONTRACTED` 4 --- * `_G._SCINTILLA.constants.SC_FOLDFLAG_LINEBEFORE_EXPANDED` 2 --- * `_G._SCINTILLA.constants.SC_FOLDLEVELBASE` 1024 --- * `_G._SCINTILLA.constants.SC_FOLDLEVELHEADERFLAG` 8192 --- * `_G._SCINTILLA.constants.SC_FOLDLEVELNUMBERMASK` 4095 --- * `_G._SCINTILLA.constants.SC_FOLDLEVELWHITEFLAG` 4096 --- * `_G._SCINTILLA.constants.SC_IV_LOOKBOTH` 3 --- * `_G._SCINTILLA.constants.SC_IV_LOOKFORWARD` 2 --- * `_G._SCINTILLA.constants.SC_IV_NONE` 0 --- * `_G._SCINTILLA.constants.SC_IV_REAL` 1 --- * `_G._SCINTILLA.constants.SC_LASTSTEPINUNDOREDO` 256 --- * `_G._SCINTILLA.constants.SC_MARGINOPTION_NONE` 0 --- * `_G._SCINTILLA.constants.SC_MARGINOPTION_SUBLINESELECT` 1 --- * `_G._SCINTILLA.constants.SC_MARGIN_BACK` 2 --- * `_G._SCINTILLA.constants.SC_MARGIN_FORE` 3 --- * `_G._SCINTILLA.constants.SC_MARGIN_NUMBER` 1 --- * `_G._SCINTILLA.constants.SC_MARGIN_RTEXT` 5 --- * `_G._SCINTILLA.constants.SC_MARGIN_SYMBOL` 0 --- * `_G._SCINTILLA.constants.SC_MARGIN_TEXT` 4 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDER` 30 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDEREND` 25 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDERMIDTAIL` 27 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDEROPEN` 31 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDEROPENMID` 26 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDERSUB` 29 --- * `_G._SCINTILLA.constants.SC_MARKNUM_FOLDERTAIL` 28 --- * `_G._SCINTILLA.constants.SC_MARK_ARROW` 2 --- * `_G._SCINTILLA.constants.SC_MARK_ARROWDOWN` 6 --- * `_G._SCINTILLA.constants.SC_MARK_ARROWS` 24 --- * `_G._SCINTILLA.constants.SC_MARK_AVAILABLE` 28 --- * `_G._SCINTILLA.constants.SC_MARK_BACKGROUND` 22 --- * `_G._SCINTILLA.constants.SC_MARK_BOXMINUS` 14 --- * `_G._SCINTILLA.constants.SC_MARK_BOXMINUSCONNECTED` 15 --- * `_G._SCINTILLA.constants.SC_MARK_BOXPLUS` 12 --- * `_G._SCINTILLA.constants.SC_MARK_BOXPLUSCONNECTED` 13 --- * `_G._SCINTILLA.constants.SC_MARK_CHARACTER` 10000 --- * `_G._SCINTILLA.constants.SC_MARK_CIRCLE` 0 --- * `_G._SCINTILLA.constants.SC_MARK_CIRCLEMINUS` 20 --- * `_G._SCINTILLA.constants.SC_MARK_CIRCLEMINUSCONNECTED` 21 --- * `_G._SCINTILLA.constants.SC_MARK_CIRCLEPLUS` 18 --- * `_G._SCINTILLA.constants.SC_MARK_CIRCLEPLUSCONNECTED` 19 --- * `_G._SCINTILLA.constants.SC_MARK_DOTDOTDOT` 23 --- * `_G._SCINTILLA.constants.SC_MARK_EMPTY` 5 --- * `_G._SCINTILLA.constants.SC_MARK_FULLRECT` 26 --- * `_G._SCINTILLA.constants.SC_MARK_LCORNER` 10 --- * `_G._SCINTILLA.constants.SC_MARK_LCORNERCURVE` 16 --- * `_G._SCINTILLA.constants.SC_MARK_LEFTRECT` 27 --- * `_G._SCINTILLA.constants.SC_MARK_MINUS` 7 --- * `_G._SCINTILLA.constants.SC_MARK_PIXMAP` 25 --- * `_G._SCINTILLA.constants.SC_MARK_PLUS` 8 --- * `_G._SCINTILLA.constants.SC_MARK_RGBAIMAGE` 30 --- * `_G._SCINTILLA.constants.SC_MARK_ROUNDRECT` 1 --- * `_G._SCINTILLA.constants.SC_MARK_SHORTARROW` 4 --- * `_G._SCINTILLA.constants.SC_MARK_SMALLRECT` 3 --- * `_G._SCINTILLA.constants.SC_MARK_TCORNER` 11 --- * `_G._SCINTILLA.constants.SC_MARK_TCORNERCURVE` 17 --- * `_G._SCINTILLA.constants.SC_MARK_UNDERLINE` 29 --- * `_G._SCINTILLA.constants.SC_MARK_VLINE` 9 --- * `_G._SCINTILLA.constants.SC_MASK_FOLDERS` -33554432 --- * `_G._SCINTILLA.constants.SC_MAX_MARGIN` 4 --- * `_G._SCINTILLA.constants.SC_MODEVENTMASKALL` 1048575 --- * `_G._SCINTILLA.constants.SC_MOD_BEFOREDELETE` 2048 --- * `_G._SCINTILLA.constants.SC_MOD_BEFOREINSERT` 1024 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGEANNOTATION` 131072 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGEFOLD` 8 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGEINDICATOR` 16384 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGELINESTATE` 32768 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGEMARGIN` 65536 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGEMARKER` 512 --- * `_G._SCINTILLA.constants.SC_MOD_CHANGESTYLE` 4 --- * `_G._SCINTILLA.constants.SC_MOD_CONTAINER` 262144 --- * `_G._SCINTILLA.constants.SC_MOD_DELETETEXT` 2 --- * `_G._SCINTILLA.constants.SC_MOD_INSERTTEXT` 1 --- * `_G._SCINTILLA.constants.SC_MOD_LEXERSTATE` 524288 --- * `_G._SCINTILLA.constants.SC_MULTILINEUNDOREDO` 4096 --- * `_G._SCINTILLA.constants.SC_MULTIPASTE_EACH` 1 --- * `_G._SCINTILLA.constants.SC_MULTIPASTE_ONCE` 0 --- * `_G._SCINTILLA.constants.SC_MULTISTEPUNDOREDO` 128 --- * `_G._SCINTILLA.constants.SC_ORDER_CUSTOM` 2 --- * `_G._SCINTILLA.constants.SC_ORDER_PERFORMSORT` 1 --- * `_G._SCINTILLA.constants.SC_ORDER_PRESORTED` 0 --- * `_G._SCINTILLA.constants.SC_PERFORMED_REDO` 64 --- * `_G._SCINTILLA.constants.SC_PERFORMED_UNDO` 32 --- * `_G._SCINTILLA.constants.SC_PERFORMED_USER` 16 --- * `_G._SCINTILLA.constants.SC_SEL_LINES` 2 --- * `_G._SCINTILLA.constants.SC_SEL_RECTANGLE` 1 --- * `_G._SCINTILLA.constants.SC_SEL_STREAM` 0 --- * `_G._SCINTILLA.constants.SC_SEL_THIN` 3 --- * `_G._SCINTILLA.constants.SC_STARTACTION` 8192 --- * `_G._SCINTILLA.constants.SC_TIME_FOREVER` 10000000 --- * `_G._SCINTILLA.constants.SC_UPDATE_CONTENT` 1 --- * `_G._SCINTILLA.constants.SC_UPDATE_H_SCROLL` 8 --- * `_G._SCINTILLA.constants.SC_UPDATE_SELECTION` 2 --- * `_G._SCINTILLA.constants.SC_UPDATE_V_SCROLL` 4 --- * `_G._SCINTILLA.constants.SC_WRAPINDENT_FIXED` 0 --- * `_G._SCINTILLA.constants.SC_WRAPINDENT_INDENT` 2 --- * `_G._SCINTILLA.constants.SC_WRAPINDENT_SAME` 1 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAGLOC_DEFAULT` 0 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAGLOC_END_BY_TEXT` 1 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAGLOC_START_BY_TEXT` 2 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAG_END` 1 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAG_MARGIN` 4 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAG_NONE` 0 --- * `_G._SCINTILLA.constants.SC_WRAPVISUALFLAG_START` 2 --- * `_G._SCINTILLA.constants.SC_WRAP_CHAR` 2 --- * `_G._SCINTILLA.constants.SC_WRAP_NONE` 0 --- * `_G._SCINTILLA.constants.SC_WRAP_WORD` 1 +-- * `_G._SCINTILLA.constants.ALPHA_NOALPHA` 256 +-- * `_G._SCINTILLA.constants.ALPHA_OPAQUE` 255 +-- * `_G._SCINTILLA.constants.ALPHA_TRANSPARENT` 0 +-- * `_G._SCINTILLA.constants.AUTOMATICFOLD_CHANGE` 4 +-- * `_G._SCINTILLA.constants.AUTOMATICFOLD_CLICK` 2 +-- * `_G._SCINTILLA.constants.AUTOMATICFOLD_SHOW` 1 +-- * `_G._SCINTILLA.constants.CARETSTICKY_OFF` 0 +-- * `_G._SCINTILLA.constants.CARETSTICKY_ON` 1 +-- * `_G._SCINTILLA.constants.CARETSTICKY_WHITESPACE` 2 +-- * `_G._SCINTILLA.constants.CASEINSENSITIVEBEHAVIOUR_IGNORECASE` 1 +-- * `_G._SCINTILLA.constants.CASEINSENSITIVEBEHAVIOUR_RESPECTCASE` 0 +-- * `_G._SCINTILLA.constants.CASE_LOWER` 2 +-- * `_G._SCINTILLA.constants.CASE_MIXED` 0 +-- * `_G._SCINTILLA.constants.CASE_UPPER` 1 +-- * `_G._SCINTILLA.constants.CP_UTF8` 65001 +-- * `_G._SCINTILLA.constants.CURSORARROW` 2 +-- * `_G._SCINTILLA.constants.CURSORNORMAL` -1 +-- * `_G._SCINTILLA.constants.CURSORREVERSEARROW` 7 +-- * `_G._SCINTILLA.constants.CURSORWAIT` 4 +-- * `_G._SCINTILLA.constants.EOL_CR` 1 +-- * `_G._SCINTILLA.constants.EOL_CRLF` 0 +-- * `_G._SCINTILLA.constants.EOL_LF` 2 +-- * `_G._SCINTILLA.constants.FOLDACTION_CONTRACT` 0 +-- * `_G._SCINTILLA.constants.FOLDACTION_EXPAND` 1 +-- * `_G._SCINTILLA.constants.FOLDACTION_TOGGLE` 2 +-- * `_G._SCINTILLA.constants.FOLDFLAG_LEVELNUMBERS` 64 +-- * `_G._SCINTILLA.constants.FOLDFLAG_LINEAFTER_CONTRACTED` 16 +-- * `_G._SCINTILLA.constants.FOLDFLAG_LINEAFTER_EXPANDED` 8 +-- * `_G._SCINTILLA.constants.FOLDFLAG_LINEBEFORE_CONTRACTED` 4 +-- * `_G._SCINTILLA.constants.FOLDFLAG_LINEBEFORE_EXPANDED` 2 +-- * `_G._SCINTILLA.constants.FOLDLEVELBASE` 1024 +-- * `_G._SCINTILLA.constants.FOLDLEVELHEADERFLAG` 8192 +-- * `_G._SCINTILLA.constants.FOLDLEVELNUMBERMASK` 4095 +-- * `_G._SCINTILLA.constants.FOLDLEVELWHITEFLAG` 4096 +-- * `_G._SCINTILLA.constants.IV_LOOKBOTH` 3 +-- * `_G._SCINTILLA.constants.IV_LOOKFORWARD` 2 +-- * `_G._SCINTILLA.constants.IV_NONE` 0 +-- * `_G._SCINTILLA.constants.IV_REAL` 1 +-- * `_G._SCINTILLA.constants.LASTSTEPINUNDOREDO` 256 +-- * `_G._SCINTILLA.constants.MARGINOPTION_NONE` 0 +-- * `_G._SCINTILLA.constants.MARGINOPTION_SUBLINESELECT` 1 +-- * `_G._SCINTILLA.constants.MARGIN_BACK` 2 +-- * `_G._SCINTILLA.constants.MARGIN_FORE` 3 +-- * `_G._SCINTILLA.constants.MARGIN_NUMBER` 1 +-- * `_G._SCINTILLA.constants.MARGIN_RTEXT` 5 +-- * `_G._SCINTILLA.constants.MARGIN_SYMBOL` 0 +-- * `_G._SCINTILLA.constants.MARGIN_TEXT` 4 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDER` 30 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDEREND` 25 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDERMIDTAIL` 27 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDEROPEN` 31 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDEROPENMID` 26 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDERSUB` 29 +-- * `_G._SCINTILLA.constants.MARKNUM_FOLDERTAIL` 28 +-- * `_G._SCINTILLA.constants.MARK_ARROW` 2 +-- * `_G._SCINTILLA.constants.MARK_ARROWDOWN` 6 +-- * `_G._SCINTILLA.constants.MARK_ARROWS` 24 +-- * `_G._SCINTILLA.constants.MARK_AVAILABLE` 28 +-- * `_G._SCINTILLA.constants.MARK_BACKGROUND` 22 +-- * `_G._SCINTILLA.constants.MARK_BOXMINUS` 14 +-- * `_G._SCINTILLA.constants.MARK_BOXMINUSCONNECTED` 15 +-- * `_G._SCINTILLA.constants.MARK_BOXPLUS` 12 +-- * `_G._SCINTILLA.constants.MARK_BOXPLUSCONNECTED` 13 +-- * `_G._SCINTILLA.constants.MARK_CHARACTER` 10000 +-- * `_G._SCINTILLA.constants.MARK_CIRCLE` 0 +-- * `_G._SCINTILLA.constants.MARK_CIRCLEMINUS` 20 +-- * `_G._SCINTILLA.constants.MARK_CIRCLEMINUSCONNECTED` 21 +-- * `_G._SCINTILLA.constants.MARK_CIRCLEPLUS` 18 +-- * `_G._SCINTILLA.constants.MARK_CIRCLEPLUSCONNECTED` 19 +-- * `_G._SCINTILLA.constants.MARK_DOTDOTDOT` 23 +-- * `_G._SCINTILLA.constants.MARK_EMPTY` 5 +-- * `_G._SCINTILLA.constants.MARK_FULLRECT` 26 +-- * `_G._SCINTILLA.constants.MARK_LCORNER` 10 +-- * `_G._SCINTILLA.constants.MARK_LCORNERCURVE` 16 +-- * `_G._SCINTILLA.constants.MARK_LEFTRECT` 27 +-- * `_G._SCINTILLA.constants.MARK_MINUS` 7 +-- * `_G._SCINTILLA.constants.MARK_PIXMAP` 25 +-- * `_G._SCINTILLA.constants.MARK_PLUS` 8 +-- * `_G._SCINTILLA.constants.MARK_RGBAIMAGE` 30 +-- * `_G._SCINTILLA.constants.MARK_ROUNDRECT` 1 +-- * `_G._SCINTILLA.constants.MARK_SHORTARROW` 4 +-- * `_G._SCINTILLA.constants.MARK_SMALLRECT` 3 +-- * `_G._SCINTILLA.constants.MARK_TCORNER` 11 +-- * `_G._SCINTILLA.constants.MARK_TCORNERCURVE` 17 +-- * `_G._SCINTILLA.constants.MARK_UNDERLINE` 29 +-- * `_G._SCINTILLA.constants.MARK_VLINE` 9 +-- * `_G._SCINTILLA.constants.MASK_FOLDERS` -33554432 +-- * `_G._SCINTILLA.constants.MAX_MARGIN` 4 +-- * `_G._SCINTILLA.constants.MODEVENTMASKALL` 1048575 +-- * `_G._SCINTILLA.constants.MOD_BEFOREDELETE` 2048 +-- * `_G._SCINTILLA.constants.MOD_BEFOREINSERT` 1024 +-- * `_G._SCINTILLA.constants.MOD_CHANGEANNOTATION` 131072 +-- * `_G._SCINTILLA.constants.MOD_CHANGEFOLD` 8 +-- * `_G._SCINTILLA.constants.MOD_CHANGEINDICATOR` 16384 +-- * `_G._SCINTILLA.constants.MOD_CHANGELINESTATE` 32768 +-- * `_G._SCINTILLA.constants.MOD_CHANGEMARGIN` 65536 +-- * `_G._SCINTILLA.constants.MOD_CHANGEMARKER` 512 +-- * `_G._SCINTILLA.constants.MOD_CHANGESTYLE` 4 +-- * `_G._SCINTILLA.constants.MOD_CONTAINER` 262144 +-- * `_G._SCINTILLA.constants.MOD_DELETETEXT` 2 +-- * `_G._SCINTILLA.constants.MOD_INSERTTEXT` 1 +-- * `_G._SCINTILLA.constants.MOD_LEXERSTATE` 524288 +-- * `_G._SCINTILLA.constants.MULTILINEUNDOREDO` 4096 +-- * `_G._SCINTILLA.constants.MULTIPASTE_EACH` 1 +-- * `_G._SCINTILLA.constants.MULTIPASTE_ONCE` 0 +-- * `_G._SCINTILLA.constants.MULTISTEPUNDOREDO` 128 +-- * `_G._SCINTILLA.constants.ORDER_CUSTOM` 2 +-- * `_G._SCINTILLA.constants.ORDER_PERFORMSORT` 1 +-- * `_G._SCINTILLA.constants.ORDER_PRESORTED` 0 +-- * `_G._SCINTILLA.constants.PERFORMED_REDO` 64 +-- * `_G._SCINTILLA.constants.PERFORMED_UNDO` 32 +-- * `_G._SCINTILLA.constants.PERFORMED_USER` 16 +-- * `_G._SCINTILLA.constants.SEL_LINES` 2 +-- * `_G._SCINTILLA.constants.SEL_RECTANGLE` 1 +-- * `_G._SCINTILLA.constants.SEL_STREAM` 0 +-- * `_G._SCINTILLA.constants.SEL_THIN` 3 +-- * `_G._SCINTILLA.constants.STARTACTION` 8192 +-- * `_G._SCINTILLA.constants.TIME_FOREVER` 10000000 +-- * `_G._SCINTILLA.constants.UPDATE_CONTENT` 1 +-- * `_G._SCINTILLA.constants.UPDATE_H_SCROLL` 8 +-- * `_G._SCINTILLA.constants.UPDATE_SELECTION` 2 +-- * `_G._SCINTILLA.constants.UPDATE_V_SCROLL` 4 +-- * `_G._SCINTILLA.constants.WRAPINDENT_FIXED` 0 +-- * `_G._SCINTILLA.constants.WRAPINDENT_INDENT` 2 +-- * `_G._SCINTILLA.constants.WRAPINDENT_SAME` 1 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAGLOC_DEFAULT` 0 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAGLOC_END_BY_TEXT` 1 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAGLOC_START_BY_TEXT` 2 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAG_END` 1 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAG_MARGIN` 4 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAG_NONE` 0 +-- * `_G._SCINTILLA.constants.WRAPVISUALFLAG_START` 2 +-- * `_G._SCINTILLA.constants.WRAP_CHAR` 2 +-- * `_G._SCINTILLA.constants.WRAP_NONE` 0 +-- * `_G._SCINTILLA.constants.WRAP_WORD` 1 -- * `_G._SCINTILLA.constants.STYLE_BRACEBAD` 35 -- * `_G._SCINTILLA.constants.STYLE_BRACELIGHT` 34 -- * `_G._SCINTILLA.constants.STYLE_CALLTIP` 38 diff --git a/core/.buffer.luadoc b/core/.buffer.luadoc index ac94b191..0e310010 100644 --- a/core/.buffer.luadoc +++ b/core/.buffer.luadoc @@ -22,7 +22,7 @@ -- @field additional_sel_alpha (number) -- The alpha value, ranging from `0` (transparent) to `255` (opaque), of -- additional selections. --- The default value is `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default value is `buffer.ALPHA_NOALPHA`, for no alpha. -- @field additional_sel_back (number, Write-only) -- The background color, in "0xBBGGRR" format, of additional selections. -- This field has no effect when calling `buffer:set_sel_back(false, ...)`. @@ -33,7 +33,7 @@ -- Type into multiple selections. -- The default value is `false`. -- @field all_lines_visible (bool, Read-only) --- Whether or not all lines in the buffer are visible. +-- Whether or not all lines are visible. -- @field anchor (number) -- The position of the anchor. -- @field annotation_lines (table, Read-only) @@ -79,12 +79,12 @@ -- The behavior mode for a case insensitive autocompletion or user list when -- [`buffer.auto_c_ignore_case`](#auto_c_ignore_case) is `true`. -- --- * `buffer.SC_CASEINSENSITIVEBEHAVIOR_RESPECTCASE` +-- * `buffer.CASEINSENSITIVEBEHAVIOR_RESPECTCASE` -- Prefer to select case-sensitive matches. --- * `buffer.SC_CASEINSENSITIVEBEHAVIOR_IGNORECASE` +-- * `buffer.CASEINSENSITIVEBEHAVIOR_IGNORECASE` -- No preference. -- --- The default value is `buffer.SC_CASEINSENSITIVEBEHAVIOR_RESPECTCASE`. +-- The default value is `buffer.CASEINSENSITIVEBEHAVIOR_RESPECTCASE`. -- @field auto_c_choose_single (bool) -- Automatically choose the item in a single-item autocompletion list. -- The default value is `false`. @@ -114,16 +114,16 @@ -- @field auto_c_order (number) -- The order setting for autocompletion lists. -- --- * `buffer.SC_ORDER_PRESORTED` +-- * `buffer.ORDER_PRESORTED` -- Lists passed to [`buffer.auto_c_show`](#auto_c_show) are in sorted, -- alphabetical order. --- * `buffer.SC_ORDER_PERFORMSORT` +-- * `buffer.ORDER_PERFORMSORT` -- Sort autocompletion lists passed to [`buffer.auto_c_show`](#auto_c_show). --- * `buffer.SC_ORDER_CUSTOM` +-- * `buffer.ORDER_CUSTOM` -- Lists passed to [`buffer.auto_c_show`](#auto_c_show) are already in a -- custom order. -- --- The default value is `buffer.SC_ORDER_PRESORTED`. +-- The default value is `buffer.ORDER_PRESORTED`. -- @field auto_c_separator (number) -- The byte value of the character that separates autocompletion list items. -- The default value is `32` (' '). @@ -162,7 +162,7 @@ -- @field caret_line_back_alpha (number) -- The background alpha value, ranging from `0` (transparent) to `255` -- (opaque), of the caret line. --- The default value is `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default value is `buffer.ALPHA_NOALPHA`, for no alpha. -- @field caret_line_visible (bool) -- Color the background of the line containing the caret a different color. -- The default value is `false`. @@ -177,16 +177,16 @@ -- @field caret_sticky (number) -- The preferred horizontal position of the caret when moving between lines. -- --- * `buffer.SC_CARETSTICKY_OFF` +-- * `buffer.CARETSTICKY_OFF` -- Use the same position as on the previous line. --- * `buffer.SC_CARETSTICKY_ON` +-- * `buffer.CARETSTICKY_ON` -- Use the last position the caret was moved to via the mouse, left/right -- arrow keys, home/end keys, etc. Typing text does not affect the position. --- * `buffer.SC_CARETSTICKY_WHITESPACE` +-- * `buffer.CARETSTICKY_WHITESPACE` -- Use the same position as on the previous line, but prior to any inserted -- indentation. -- --- The default value is `buffer.SC_CARETSTICKY_OFF`. +-- The default value is `buffer.CARETSTICKY_OFF`. -- @field caret_style (number) -- The visual style of the caret. -- @@ -203,10 +203,10 @@ -- and only applicable to line carets. -- The default value is `1`. -- @field char_at (table, Read-only) --- Table of character bytes at positions in the buffer starting from zero. +-- Table of character bytes at positions starting from zero. -- @field column (table, Read-only) --- Table of column numbers, taking tab widths into account, for positions in --- the buffer starting from zero. +-- Table of column numbers, taking tab widths into account, for positions +-- starting from zero. -- @field control_char_symbol (number) -- The byte value of the character displayed in place of control characters, -- characters whose byte values are less than 32. Values less than 32 dispay @@ -218,16 +218,16 @@ -- @field cursor (number) -- The display cursor type. -- --- * `buffer.SC_CURSORNORMAL` +-- * `buffer.CURSORNORMAL` -- The text insert cursor. --- * `buffer.SC_CURSORARROW` +-- * `buffer.CURSORARROW` -- The arrow cursor. --- * `buffer.SC_CURSORWAIT` +-- * `buffer.CURSORWAIT` -- The wait cursor. --- * `buffer.SC_CURSORREVERSEARROW` +-- * `buffer.CURSORREVERSEARROW` -- The reversed arrow cursor. -- --- The default value is `buffer.SC_CURSORNORMAL`. +-- The default value is `buffer.CURSORNORMAL`. -- @field dirty (bool) -- Whether or not the buffer has unsaved changes. -- This field is accessible from any buffer, not just the global one. @@ -261,15 +261,15 @@ -- The current end of line mode. Changing the mode does not convert existing -- line endings. Use [`buffer:convert_eo_ls()`](#convert_eo_ls) to do so. -- --- * `buffer.SC_EOL_CRLF` +-- * `buffer.EOL_CRLF` -- Carriage return with line feed ("\r\n"). --- * `buffer.SC_EOL_CR` +-- * `buffer.EOL_CR` -- Carriage return ("\r"). --- * `buffer.SC_EOL_LF` +-- * `buffer.EOL_LF` -- Line feed ("\n"). -- --- The default value is `buffer.SC_EOL_CRLF` on Windows platforms, --- `buffer.SC_EOL_LF` otherwise. +-- The default value is `buffer.EOL_CRLF` on Windows platforms, +-- `buffer.EOL_LF` otherwise. -- @field extra_ascent (number) -- The amount of pixel padding above line text. -- The default value is `0`. @@ -288,13 +288,13 @@ -- @field fold_flags (number) -- Bit-mask of options for drawing folding lines. -- --- * `buffer.SC_FOLDFLAG_LINEBEFORE_EXPANDED` +-- * `buffer.FOLDFLAG_LINEBEFORE_EXPANDED` -- Draw lines above expanded folds. --- * `buffer.SC_FOLDFLAG_LINEBEFORE_CONTRACTED` +-- * `buffer.FOLDFLAG_LINEBEFORE_CONTRACTED` -- Draw lines above collapsed folds. --- * `buffer.SC_FOLDFLAG_LINEAFTER_EXPANDED` +-- * `buffer.FOLDFLAG_LINEAFTER_EXPANDED` -- Draw lines below expanded folds. --- * `buffer.SC_FOLDFLAG_LINEAFTER_CONTRACTED` +-- * `buffer.FOLDFLAG_LINEAFTER_CONTRACTED` -- Draw lines below collapsed folds. -- -- The default value is `0`. @@ -303,11 +303,11 @@ -- Fold level masks are composed of an integer level combined with any of the -- following bits: -- --- * `buffer.SC_FOLDLEVELBASE` +-- * `buffer.FOLDLEVELBASE` -- The initial fold level. --- * `buffer.SC_FOLDLEVELWHITEFLAG` +-- * `buffer.FOLDLEVELWHITEFLAG` -- The line is blank. --- * `buffer.SC_FOLDLEVELHEADERFLAG` +-- * `buffer.FOLDLEVELHEADERFLAG` -- The line is a header, or fold point. -- @field fold_parent (table, Read-only) -- Table of parent line numbers (fold points) for child line numbers starting @@ -334,24 +334,24 @@ -- Indentation guides are dotted vertical lines that appear within indentation -- whitespace at each level of indentation. -- --- * `buffer.SC_IV_NONE` +-- * `buffer.IV_NONE` -- Does not draw any guides. --- * `buffer.SC_IV_REAL` +-- * `buffer.IV_REAL` -- Draw guides only within indentation whitespace. --- * `buffer.SC_IV_LOOKFORWARD` +-- * `buffer.IV_LOOKFORWARD` -- Draw guides beyond the current line up to the level of the next non-empty -- line, but with an additional level if the previous non-empty line is a -- fold header. --- * `buffer.SC_IV_LOOKBOTH` +-- * `buffer.IV_LOOKBOTH` -- Draw guides beyond the current line up to either the level of the -- previous or next non-empty line, whichever is greater. -- --- The default value is `buffer.SC_IV_NONE`. +-- The default value is `buffer.IV_NONE`. -- @field indic_alpha (table) -- Table of fill color alpha values, ranging from `0` (transparent) to `255` -- (opaque), for indicator numbers from `0` to `31` whose styles are either -- `INDIC_ROUNDBOX`, `INDIC_STRAIGHTBOX`, or `INDIC_DOTBOX`. --- The default values are `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default values are `buffer.ALPHA_NOALPHA`, for no alpha. -- @field indic_fore (table) -- Table of foreground colors, in "0xBBGGRR" format, for indicator numbers -- from `0` to `31`. @@ -359,7 +359,7 @@ -- Table of outline color alpha values, ranging from `0` (transparent) to -- `255` (opaque), for indicator numbers from `0` to `31` whose styles are -- either `INDIC_ROUNDBOX`, `INDIC_STRAIGHTBOX`, or `INDIC_DOTBOX`. --- The default values are `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default values are `buffer.ALPHA_NOALPHA`, for no alpha. -- @field indic_style (table) -- Table of styles for indicator numbers from `0` to `31`. -- @@ -448,12 +448,12 @@ -- @field margin_cursor_n (table) -- Table of cursor types shown over margin numbers from zero to four. -- --- * `buffer.SC_CURSORARROW` +-- * `buffer.CURSORARROW` -- Normal arrow cursor. --- * `buffer.SC_CURSORREVERSEARROW` +-- * `buffer.CURSORREVERSEARROW` -- Reversed arrow cursor. -- --- The default values are `buffer.SC_CURSORREVERSEARROW`. +-- The default values are `buffer.CURSORREVERSEARROW`. -- @field margin_left (number) -- The pixel size of the left margin of the buffer text. -- The default value is `1`. @@ -462,18 +462,18 @@ -- numbers from zero to four. -- Bit-masks are 32-bit values whose bits correspond to the 32 available -- markers. --- The default values are `0`, `bit32.bnot(buffer.SC_MASK_FOLDERS)`, `0`, `0`, +-- The default values are `0`, `bit32.bnot(buffer.MASK_FOLDERS)`, `0`, `0`, -- and `0`, for a line margin and logical marker margin. -- @field margin_options (number) -- A bit-mask of margin option settings. -- --- * `buffer.SC_MARGINOPTION_NONE` +-- * `buffer.MARGINOPTION_NONE` -- None. --- * `buffer.SC_MARGINOPTION_SUBLINESELECT` +-- * `buffer.MARGINOPTION_SUBLINESELECT` -- Select only the sub-line of the wrapped line, rather than the entire -- line, on margin click. -- --- The default value is `buffer.SC_MARGINOPTION_NONE`. +-- The default value is `buffer.MARGINOPTION_NONE`. -- @field margin_right (number) -- The pixel size of the right margin of the buffer text. -- The default value is `1`. @@ -502,19 +502,19 @@ -- @field margin_type_n (table) -- Table of margin types for margin numbers from zero to four. -- --- * `buffer.SC_MARGIN_SYMBOL` +-- * `buffer.MARGIN_SYMBOL` -- A symbol margin. --- * `buffer.SC_MARGIN_NUMBER` +-- * `buffer.MARGIN_NUMBER` -- A line number margin. --- * `buffer.SC_MARGIN_BACK` +-- * `buffer.MARGIN_BACK` -- A symbol margin whose background color matches the default text -- background color. --- * `buffer.SC_MARGIN_FORE` +-- * `buffer.MARGIN_FORE` -- A symbol margin whose foreground color matches the default text -- foreground color. --- * `buffer.SC_MARGIN_TEXT` +-- * `buffer.MARGIN_TEXT` -- A text margin. --- * `buffer.SC_MARGIN_RTEXT` +-- * `buffer.MARGIN_RTEXT` -- A right-justified text margin. -- -- The default values are `true`, `false`, `false`, `false`, and `false`, for @@ -525,7 +525,7 @@ -- Table of alpha values, ranging from `0` (transparent) to `255` (opaque), -- of markers drawn in the text area, not the margin, for markers numbers from -- `0` to `31`. --- The default values are `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default values are `buffer.ALPHA_NOALPHA`, for no alpha. -- @field marker_back (table, Write-only) -- Table of background colors, in "0xBBGGRR" format, of marker numbers from -- `0` to `31`. @@ -540,17 +540,17 @@ -- The last line number with a non-zero line state. -- @field mouse_dwell_time (number) -- The number of milliseconds the mouse must idle before generating a --- `DWELL_START` event. A time of `buffer.SC_TIME_FOREVER` will never generate +-- `DWELL_START` event. A time of `buffer.TIME_FOREVER` will never generate -- one. -- @field multi_paste (number) -- The multiple selection paste mode. -- --- * `buffer.SC_MULTIPASTE_ONCE` +-- * `buffer.MULTIPASTE_ONCE` -- Paste into only the main selection. --- * `buffer.SC_MULTIPASTE_EACH` +-- * `buffer.MULTIPASTE_EACH` -- Paste into all selections. -- --- The default value is `buffer.SC_MULTIPASTE_ONCE`. +-- The default value is `buffer.MULTIPASTE_ONCE`. -- @field multiple_selection (bool) -- Enable multiple selection. -- The default value is `false`. @@ -671,7 +671,7 @@ -- @field sel_alpha (number) -- The alpha value, ranging from `0` (transparent) to `255` (opaque), of the -- selection. --- The default value is `buffer.SC_ALPHA_NOALPHA`, for no alpha. +-- The default value is `buffer.ALPHA_NOALPHA`, for no alpha. -- @field sel_eol_filled (bool) -- Extend the selection to the right margin of the view. -- The default value is `false`. @@ -685,13 +685,13 @@ -- @field selection_mode (number) -- The selection mode. -- --- * `buffer.SC_SEL_STREAM` +-- * `buffer.SEL_STREAM` -- Character selection. --- * `buffer.SC_SEL_RECTANGLE` +-- * `buffer.SEL_RECTANGLE` -- Rectangular selection. --- * `buffer.SC_SEL_LINES` +-- * `buffer.SEL_LINES` -- Line selection. --- * `buffer.SC_SEL_THIN` +-- * `buffer.SEL_THIN` -- Thin rectangular selection. This is the mode after a rectangular -- selection has been typed into and ensures that no characters are -- selected. @@ -722,7 +722,7 @@ -- @field selections (number, Read-only) -- The number of active selections. -- @field style_at (table, Read-only) --- Table of style numbers at positions in the buffer starting from zero. +-- Table of style numbers at positions starting from zero. -- @field style_back (table) -- Table of background colors, in "0xBBGGRR" format, of text within styles for -- style numbers from `0` to `255`. @@ -734,14 +734,14 @@ -- Table of letter case modes of text within styles for style numbers from `0` -- to `255`. -- --- * `buffer.SC_CASE_MIXED` +-- * `buffer.CASE_MIXED` -- Display text in normally. --- * `buffer.SC_CASE_UPPER` +-- * `buffer.CASE_UPPER` -- Display text in upper case. --- * `buffer.SC_CASE_LOWER` +-- * `buffer.CASE_LOWER` -- Display text in lower case. -- --- The default values are `buffer.SC_CASE_MIXED`. +-- The default values are `buffer.CASE_MIXED`. -- @field style_changeable (table) -- Table of flags indicating whether or not text within styles is changeable -- for style numbers from `0` to `255`. @@ -856,54 +856,54 @@ -- @field wrap_indent_mode (number) -- The wrapped line indent mode. -- --- * `buffer.SC_WRAPINDENT_FIXED` +-- * `buffer.WRAPINDENT_FIXED` -- Indent wrapped lines by [`buffer.wrap_start_indent`](#wrap_start_indent). --- * `buffer.SC_WRAPINDENT_SAME` +-- * `buffer.WRAPINDENT_SAME` -- Indent wrapped lines the same as the first line. --- * `buffer.SC_WRAPINDENT_INDENT` +-- * `buffer.WRAPINDENT_INDENT` -- Indent wrapped lines one more level than the first line. -- --- The default value is `buffer.SC_WRAPINDENT_FIXED`. +-- The default value is `buffer.WRAPINDENT_FIXED`. -- @field wrap_mode (number) -- Long line wrap mode. -- --- * `buffer.SC_WRAP_NONE` +-- * `buffer.WRAP_NONE` -- Long lines are not wrapped. --- * `buffer.SC_WRAP_WORD` +-- * `buffer.WRAP_WORD` -- Wrap long lines at word boundaries. --- * `buffer.SC_WRAP_CHAR` +-- * `buffer.WRAP_CHAR` -- Wrap long lines at character boundaries. -- --- The default value is `buffer.SC_WRAP_NONE`. +-- The default value is `buffer.WRAP_NONE`. -- @field wrap_start_indent (number) -- The number of spaces to indent wrapped lines by if -- [`buffer.wrap_indent_mode`](#wrap_indent_mode) is --- `buffer.SC_WRAP_INDENT_FIXED`. +-- `buffer.WRAP_INDENT_FIXED`. -- The default value is `0`. -- @field wrap_visual_flags (number) -- The wrapped line visual display mode. -- --- * `buffer.SC_WRAPVISUALFLAG_NONE` +-- * `buffer.WRAPVISUALFLAG_NONE` -- No visual flags. --- * `buffer.SC_WRAPVISUALFLAG_END` +-- * `buffer.WRAPVISUALFLAG_END` -- Show visual flag at the end of the line. --- * `buffer.SC_WRAPVISUALFLAG_START` +-- * `buffer.WRAPVISUALFLAG_START` -- Show visual flag at the beginning of the sub-line. --- * `buffer.SC_WRAPVISUALFLAG_MARGIN` +-- * `buffer.WRAPVISUALFLAG_MARGIN` -- Show visual flag in the line number margin of the sub-line. -- --- The default value is `buffer.SC_WRAPVISUALFLAG_NONE`. +-- The default value is `buffer.WRAPVISUALFLAG_NONE`. -- @field wrap_visual_flags_location (number) -- The wrapped line visual flag drawing mode. -- --- * `buffer.SC_WRAPVISUALFLAGLOC_DEFAULT` +-- * `buffer.WRAPVISUALFLAGLOC_DEFAULT` -- Draw the visual flag near the right border. --- * `buffer.SC_WRAPVISUALFLAGLOC_END_BY_TEXT` +-- * `buffer.WRAPVISUALFLAGLOC_END_BY_TEXT` -- Draw the visual flag near text at the end of the line. --- * `buffer.SC_WRAPVISUALFLAGLOC_START_BY_TEXT` +-- * `buffer.WRAPVISUALFLAGLOC_START_BY_TEXT` -- Draw the visual flag near text at the beginning of the subline. -- --- The default value is `buffer.SC_WRAPVISUALFLAGLOC_DEFAULT`. +-- The default value is `buffer.WRAPVISUALFLAGLOC_DEFAULT`. -- @field x_offset (number) -- The horizontal scroll position in pixels. -- A value of `0` is the normal position with the first text column visible at @@ -1200,12 +1200,12 @@ function choose_caret_x(buffer) end function clear(buffer) end --- --- Deletes all of the text in the buffer. +-- Deletes the buffer's text. -- @param buffer The global buffer. function clear_all(buffer) end --- --- Clears all styling and folding information in the buffer. +-- Clears all styling and folding information. -- @param buffer The global buffer. function clear_document_style(buffer) end @@ -1243,9 +1243,9 @@ function contracted_fold_next(buffer, line_start) end -- Converts all line endings to end of line mode *mode*. -- @param buffer The global buffer. -- @param mode The line ending mode to convert to. Valid values are: --- * `buffer.SC_EOL_CRLF` --- * `buffer.SC_EOL_CR` --- * `buffer.SC_EOL_LF` +-- * `buffer.EOL_CRLF` +-- * `buffer.EOL_CR` +-- * `buffer.EOL_LF` function convert_eo_ls(buffer, mode) end --- @@ -1337,8 +1337,7 @@ function delete_back(buffer) end function delete_back_not_line(buffer) end --- --- Deletes the range of text from position *pos* to *pos* + *length* in the --- buffer. +-- Deletes the buffer's text from position *pos* to *pos* + *length*. -- @param buffer The global buffer. -- @param pos The start position of the range of text in *buffer* to delete. -- @param length The number of characters in the range of text to delete. @@ -1427,15 +1426,15 @@ function expand_children(buffer, line, level) end function find_column(buffer, line, column) end --- --- Expands, contracts, or toggles the fold states of all fold headers in the --- buffer, depending on *action*. --- When toggling, the state of the first fold header in the buffer determines --- whether to expand or contract. +-- Expands, contracts, or toggles the fold states of all fold headers, depending +-- on *action*. +-- When toggling, the state of the first fold header determines whether to +-- expand or contract. -- @param buffer The global buffer. -- @param action The fold action to perform. Valid values are: --- * `buffer.SC_FOLDACTION_CONTRACT` --- * `buffer.SC_FOLDACTION_EXPAND` --- * `buffer.SC_FOLDACTION_TOGGLE` +-- * `buffer.FOLDACTION_CONTRACT` +-- * `buffer.FOLDACTION_EXPAND` +-- * `buffer.FOLDACTION_TOGGLE` function fold_all(buffer, action) end --- @@ -1444,9 +1443,9 @@ function fold_all(buffer, action) end -- @param buffer The global buffer. -- @param line The line number in *buffer* to set the fold states for. -- @param action The fold action to perform. Valid values are: --- * `buffer.SC_FOLDACTION_CONTRACT` --- * `buffer.SC_FOLDACTION_EXPAND` --- * `buffer.SC_FOLDACTION_TOGGLE` +-- * `buffer.FOLDACTION_CONTRACT` +-- * `buffer.FOLDACTION_EXPAND` +-- * `buffer.FOLDACTION_TOGGLE` function fold_children(buffer, line, action) end --- @@ -1455,13 +1454,13 @@ function fold_children(buffer, line, action) end -- @param buffer The global buffer. -- @param line The line number in *buffer* to set the fold state for. -- @param action The fold action to perform. Valid values are: --- * `buffer.SC_FOLDACTION_CONTRACT` --- * `buffer.SC_FOLDACTION_EXPAND` --- * `buffer.SC_FOLDACTION_TOGGLE` +-- * `buffer.FOLDACTION_CONTRACT` +-- * `buffer.FOLDACTION_EXPAND` +-- * `buffer.FOLDACTION_TOGGLE` function fold_line(buffer, line, action) end --- --- Inserts a Form Feed ("\f") character at the caret position. +-- Types a Form Feed ("\f") character at the caret position. -- @param buffer The global buffer. function form_feed(buffer) end @@ -1524,7 +1523,7 @@ function get_line_sel_start_position(buffer, line) end function get_sel_text(buffer) end --- --- Returns all of the text in the buffer. +-- Returns the buffer's text. -- @param buffer The global buffer. function get_text(buffer) end @@ -1641,7 +1640,7 @@ function indicator_start(buffer, indicator, pos) end --- -- Inserts string *text* at position *pos* or the caret position if *pos* is --- `-1`. +-- `-1`, removing any selections. -- If the caret is after the *pos*, it is moved appropriately, but not scrolled -- into view. -- @param buffer The global buffer. @@ -1839,14 +1838,14 @@ function marker_add_set(buffer, line, marker_mask) end -- @param buffer The global buffer. -- @param marker_num The marker number in the range of `0` to `31` to set -- *marker_symbol* for. --- @param marker_symbol The marker symbol: `buffer.SC_MARK_*`. +-- @param marker_symbol The marker symbol: `buffer.MARK_*`. -- @see _SCINTILLA.next_marker_number function marker_define(buffer, marker_num, marker_symbol) end --- -- Associates marker number *marker_num*, in the range of `0` to `31`, with XPM -- image *pixmap*. --- The `buffer.SC_MARK_PIXMAP` symbol must be associated with *marker_num*. +-- The `buffer.MARK_PIXMAP` symbol must be associated with *marker_num*. -- The image is shown in symbol margins next to lines marked with *marker_num*. -- @param buffer The global buffer. -- @param marker_num The marker number in the range of `0` to `31` to define @@ -1861,9 +1860,9 @@ function marker_define_pixmap(buffer, marker_num, pixmap) end -- `buffer.rgba_image_height`, must have already been defined. *pixels* is a -- sequence of 4 byte pixel values (red, blue, green, and alpha) defining the -- image line by line starting at the top-left pixel. --- The `buffer.SC_MARK_RGBAIMAGE` symbol must be associated with *marker_num*. +-- The `buffer.MARK_RGBAIMAGE` symbol must be associated with *marker_num*. -- The image is shown in symbol margins next to lines marked with *marker_num*. --- RGBA image markers use the `buffer.SC_MARK_RGBAIMAGE` marker symbol. +-- RGBA image markers use the `buffer.MARK_RGBAIMAGE` marker symbol. -- @param buffer The global buffer. -- @param marker_num The marker number in the range of `0` to `31` to define -- RGBA data *pixels* for. @@ -1886,8 +1885,9 @@ function marker_define_rgba_image(buffer, marker_num, pixels) end function marker_delete(buffer, line, marker_num) end --- --- Deletes marker number *marker_num*, in the range of `0` to `31` or `-1` for --- all markers, from all lines in the buffer. +-- Deletes marker number *marker_num*, in the range of `0` to `31`, from any +-- line that has it. +-- If *marker_num* is `-1`, deletes all markers from all lines. -- @param buffer The global buffer. -- @param marker_num The marker number in the range of `0` to `31` to delete -- from all lines, or `-1` to delete all markers from all lines. @@ -1974,7 +1974,7 @@ function move_selected_lines_down(buffer) end function move_selected_lines_up(buffer) end --- --- Inserts a new line at the caret position based on +-- Types a new line at the caret position based on -- [`buffer.eol_mode`](#eol_mode). -- @param buffer The global buffer. function new_line(buffer) end @@ -2120,9 +2120,10 @@ function release_all_extended_styles(buffer) end function replace_sel(buffer, text) end --- --- Replaces the text in the target range with string *text*. --- The recommended way to delete text in the buffer is to set the target to the --- text to be removed, and to call this function with an empty string. +-- Replaces the text in the target range with string *text* without modifying +-- any selections or scrolling the view. +-- Setting the target and calling this function with an empty string is another +-- way to delete text. -- @param buffer The global buffer. -- @param text The text to replace the target range with. -- @return number @@ -2213,7 +2214,7 @@ function search_next(buffer, flags, text) end function search_prev(buffer, flags, text) end --- --- Selects all of the text in the buffer without scrolling the view. +-- Selects all of the buffer's text without scrolling the view. -- @param buffer The global buffer. function select_all(buffer) end @@ -2277,8 +2278,8 @@ function set_hotspot_active_fore(buffer, use_setting, color) end function set_save_point(buffer) end --- --- Selects the range of text between positions *start_pos* and *end_pos* in the --- buffer, scrolling the selected text into view. +-- Selects the buffer's text between positions *start_pos* and *end_pos*, +-- scrolling the selected text into view. -- @param buffer The global buffer. -- @param start_pos The start position of the range of text in *buffer* to -- select. If negative, it means the end of the buffer. @@ -2304,8 +2305,8 @@ function set_sel_back(buffer, use_setting, color) end function set_sel_fore(buffer, use_setting, color) end --- --- Selects the range of text between positions *start_pos* to *end_pos* in the --- buffer, removing all other selections. +-- Selects the buffer's text between positions *start_pos* to *end_pos*, +-- removing all other selections. -- @param buffer The global buffer. -- @param end_pos The caret position of the range of text to select in *buffer*. -- @param start_pos The anchor position of the range of text to select in @@ -2322,7 +2323,7 @@ function set_selection(buffer, end_pos, start_pos) end function set_styling(buffer, length, style) end --- --- Replaces all of the text in the buffer with string *text*. +-- Replaces the buffer's text with string *text*. -- @param buffer The global buffer. -- @param text The text to set. function set_text(buffer, text) end @@ -2431,7 +2432,7 @@ function style_reset_default(buffer) end function swap_main_anchor_caret(buffer) end --- --- Indents the text on the selected lines or inserts a Tab character ("\t") at +-- Indents the text on the selected lines or types a Tab character ("\t") at -- the caret position. -- @param buffer The global buffer. function tab(buffer) end @@ -2459,8 +2460,8 @@ function text_height(buffer, line) end function text_width(buffer, style_num, text) end --- --- Cycles between caret sticky option settings `buffer.SC_CARETSTICKY_ON`, --- `buffer.SC_CARETSTICKY_WHITESPACE`, and `buffer.SC_CARETSTICKY_OFF`. +-- Cycles between caret sticky option settings `buffer.CARETSTICKY_ON`, +-- `buffer.CARETSTICKY_WHITESPACE`, and `buffer.CARETSTICKY_OFF`. -- @param buffer The global buffer. -- @see caret_sticky function toggle_caret_sticky(buffer) end @@ -2706,8 +2707,7 @@ function delete(buffer) end function new() end --- --- Returns the range of text between positions *start_pos* and *end_pos* in the --- buffer. +-- Returns the buffer's text between positions *start_pos* and *end_pos*. -- @param buffer The global buffer. -- @param start_pos The start position of the range of text to get in *buffer*. -- @param end_pos The end position of the range of text to get in *buffer*. diff --git a/core/.view.luadoc b/core/.view.luadoc index 29509f9b..d1a09450 100644 --- a/core/.view.luadoc +++ b/core/.view.luadoc @@ -36,8 +36,8 @@ function unsplit(view) end --- -- Goes to buffer number *n* in the view. --- If *relative* is `true`, *n* is an index relative to the index of the current --- buffer in `_G._BUFFERS` instead of an absolute index. +-- *relative* indicates whether or not *n* is an index relative to the index of +-- the current buffer in `_G._BUFFERS` instead of an absolute index. -- Emits `BUFFER_BEFORE_SWITCH` and `BUFFER_AFTER_SWITCH` events. -- @param view The view to switch buffers in. -- @param n A relative or absolute buffer index in `_G._BUFFERS`. An absolute diff --git a/core/file_io.lua b/core/file_io.lua index 72584675..17ca2824 100644 --- a/core/file_io.lua +++ b/core/file_io.lua @@ -138,13 +138,13 @@ function io.open_file(filenames) end if not buffer.encoding then error(_L['Encoding conversion failed.']) end end - buffer.code_page = buffer.encoding and buffer.SC_CP_UTF8 or 0 + buffer.code_page = buffer.encoding and buffer.CP_UTF8 or 0 -- Detect EOL mode. local s, e = text:find('\r\n?') if s and e then - buffer.eol_mode = (s == e and buffer.SC_EOL_CR or buffer.SC_EOL_CRLF) + buffer.eol_mode = (s == e and buffer.EOL_CR or buffer.EOL_CRLF) else - buffer.eol_mode = buffer.SC_EOL_LF + buffer.eol_mode = buffer.EOL_LF end buffer:add_text(text, #text) buffer:goto_pos(0) diff --git a/core/iface.lua b/core/iface.lua index 56845343..2af60a26 100644 --- a/core/iface.lua +++ b/core/iface.lua @@ -13,7 +13,7 @@ module('_SCINTILLA')]] -- Map of Scintilla constant names to their numeric values. -- @class table -- @name constants -M.constants = {ANNOTATION_BOXED=2,ANNOTATION_HIDDEN=0,ANNOTATION_STANDARD=1,CARETSTYLE_BLOCK=2,CARETSTYLE_INVISIBLE=0,CARETSTYLE_LINE=1,CARET_EVEN=0x08,CARET_JUMPS=0x10,CARET_SLOP=0x01,CARET_STRICT=0x04,EDGE_BACKGROUND=2,EDGE_LINE=1,EDGE_NONE=0,INDIC_BOX=6,INDIC_COMPOSITIONTHICK=14,INDIC_CONTAINER=8,INDIC_DASH=9,INDIC_DIAGONAL=3,INDIC_DOTBOX=12,INDIC_DOTS=10,INDIC_HIDDEN=5,INDIC_MAX=31,INDIC_PLAIN=0,INDIC_ROUNDBOX=7,INDIC_SQUIGGLE=1,INDIC_SQUIGGLELOW=11,INDIC_SQUIGGLEPIXMAP=13,INDIC_STRAIGHTBOX=8,INDIC_STRIKE=4,INDIC_TT=2,MARKER_MAX=31,SCFIND_MATCHCASE=4,SCFIND_POSIX=0x00400000,SCFIND_REGEXP=0x00200000,SCFIND_WHOLEWORD=2,SCFIND_WORDSTART=0x00100000,SCK_ADD=310,SCK_BACK=8,SCK_DELETE=308,SCK_DIVIDE=312,SCK_DOWN=300,SCK_END=305,SCK_ESCAPE=7,SCK_HOME=304,SCK_INSERT=309,SCK_LEFT=302,SCK_MENU=315,SCK_NEXT=307,SCK_PRIOR=306,SCK_RETURN=13,SCK_RIGHT=303,SCK_RWIN=314,SCK_SUBTRACT=311,SCK_TAB=9,SCK_UP=301,SCK_WIN=313,SCMOD_ALT=4,SCMOD_CTRL=2,SCMOD_META=16,SCMOD_NORM=0,SCMOD_SHIFT=1,SCMOD_SUPER=8,SCVS_NONE=0,SCVS_RECTANGULARSELECTION=1,SCVS_USERACCESSIBLE=2,SCWS_INVISIBLE=0,SCWS_VISIBLEAFTERINDENT=2,SCWS_VISIBLEALWAYS=1,SC_ALPHA_NOALPHA=256,SC_ALPHA_OPAQUE=255,SC_ALPHA_TRANSPARENT=0,SC_AUTOMATICFOLD_CHANGE=0x0004,SC_AUTOMATICFOLD_CLICK=0x0002,SC_AUTOMATICFOLD_SHOW=0x0001,SC_CARETSTICKY_OFF=0,SC_CARETSTICKY_ON=1,SC_CARETSTICKY_WHITESPACE=2,SC_CASEINSENSITIVEBEHAVIOUR_IGNORECASE=1,SC_CASEINSENSITIVEBEHAVIOUR_RESPECTCASE=0,SC_CASE_LOWER=2,SC_CASE_MIXED=0,SC_CASE_UPPER=1,SC_CP_UTF8=65001,SC_CURSORARROW=2,SC_CURSORNORMAL=-1,SC_CURSORREVERSEARROW=7,SC_CURSORWAIT=4,SC_EOL_CR=1,SC_EOL_CRLF=0,SC_EOL_LF=2,SC_FOLDACTION_CONTRACT=0,SC_FOLDACTION_EXPAND=1,SC_FOLDACTION_TOGGLE=2,SC_FOLDFLAG_LEVELNUMBERS=0x0040,SC_FOLDFLAG_LINEAFTER_CONTRACTED=0x0010,SC_FOLDFLAG_LINEAFTER_EXPANDED=0x0008,SC_FOLDFLAG_LINEBEFORE_CONTRACTED=0x0004,SC_FOLDFLAG_LINEBEFORE_EXPANDED=0x0002,SC_FOLDLEVELBASE=0x400,SC_FOLDLEVELHEADERFLAG=0x2000,SC_FOLDLEVELNUMBERMASK=0x0FFF,SC_FOLDLEVELWHITEFLAG=0x1000,SC_IV_LOOKBOTH=3,SC_IV_LOOKFORWARD=2,SC_IV_NONE=0,SC_IV_REAL=1,SC_LASTSTEPINUNDOREDO=0x100,SC_MARGINOPTION_NONE=0,SC_MARGINOPTION_SUBLINESELECT=1,SC_MARGIN_BACK=2,SC_MARGIN_FORE=3,SC_MARGIN_NUMBER=1,SC_MARGIN_RTEXT=5,SC_MARGIN_SYMBOL=0,SC_MARGIN_TEXT=4,SC_MARKNUM_FOLDER=30,SC_MARKNUM_FOLDEREND=25,SC_MARKNUM_FOLDERMIDTAIL=27,SC_MARKNUM_FOLDEROPEN=31,SC_MARKNUM_FOLDEROPENMID=26,SC_MARKNUM_FOLDERSUB=29,SC_MARKNUM_FOLDERTAIL=28,SC_MARK_ARROW=2,SC_MARK_ARROWDOWN=6,SC_MARK_ARROWS=24,SC_MARK_AVAILABLE=28,SC_MARK_BACKGROUND=22,SC_MARK_BOXMINUS=14,SC_MARK_BOXMINUSCONNECTED=15,SC_MARK_BOXPLUS=12,SC_MARK_BOXPLUSCONNECTED=13,SC_MARK_CHARACTER=10000,SC_MARK_CIRCLE=0,SC_MARK_CIRCLEMINUS=20,SC_MARK_CIRCLEMINUSCONNECTED=21,SC_MARK_CIRCLEPLUS=18,SC_MARK_CIRCLEPLUSCONNECTED=19,SC_MARK_DOTDOTDOT=23,SC_MARK_EMPTY=5,SC_MARK_FULLRECT=26,SC_MARK_LCORNER=10,SC_MARK_LCORNERCURVE=16,SC_MARK_LEFTRECT=27,SC_MARK_MINUS=7,SC_MARK_PIXMAP=25,SC_MARK_PLUS=8,SC_MARK_RGBAIMAGE=30,SC_MARK_ROUNDRECT=1,SC_MARK_SHORTARROW=4,SC_MARK_SMALLRECT=3,SC_MARK_TCORNER=11,SC_MARK_TCORNERCURVE=17,SC_MARK_UNDERLINE=29,SC_MARK_VLINE=9,SC_MASK_FOLDERS=-33554432,SC_MAX_MARGIN=4,SC_MODEVENTMASKALL=0xFFFFF,SC_MOD_BEFOREDELETE=0x800,SC_MOD_BEFOREINSERT=0x400,SC_MOD_CHANGEANNOTATION=0x20000,SC_MOD_CHANGEFOLD=0x8,SC_MOD_CHANGEINDICATOR=0x4000,SC_MOD_CHANGELINESTATE=0x8000,SC_MOD_CHANGEMARGIN=0x10000,SC_MOD_CHANGEMARKER=0x200,SC_MOD_CHANGESTYLE=0x4,SC_MOD_CONTAINER=0x40000,SC_MOD_DELETETEXT=0x2,SC_MOD_INSERTTEXT=0x1,SC_MOD_LEXERSTATE=0x80000,SC_MULTILINEUNDOREDO=0x1000,SC_MULTIPASTE_EACH=1,SC_MULTIPASTE_ONCE=0,SC_MULTISTEPUNDOREDO=0x80,SC_ORDER_CUSTOM=2,SC_ORDER_PERFORMSORT=1,SC_ORDER_PRESORTED=0,SC_PERFORMED_REDO=0x40,SC_PERFORMED_UNDO=0x20,SC_PERFORMED_USER=0x10,SC_SEL_LINES=2,SC_SEL_RECTANGLE=1,SC_SEL_STREAM=0,SC_SEL_THIN=3,SC_STARTACTION=0x2000,SC_TIME_FOREVER=10000000,SC_UPDATE_CONTENT=0x1,SC_UPDATE_H_SCROLL=0x8,SC_UPDATE_SELECTION=0x2,SC_UPDATE_V_SCROLL=0x4,SC_WRAPINDENT_FIXED=0,SC_WRAPINDENT_INDENT=2,SC_WRAPINDENT_SAME=1,SC_WRAPVISUALFLAGLOC_DEFAULT=0x0000,SC_WRAPVISUALFLAGLOC_END_BY_TEXT=0x0001,SC_WRAPVISUALFLAGLOC_START_BY_TEXT=0x0002,SC_WRAPVISUALFLAG_END=0x0001,SC_WRAPVISUALFLAG_MARGIN=0x0004,SC_WRAPVISUALFLAG_NONE=0x0000,SC_WRAPVISUALFLAG_START=0x0002,SC_WRAP_CHAR=2,SC_WRAP_NONE=0,SC_WRAP_WORD=1,STYLE_BRACEBAD=35,STYLE_BRACELIGHT=34,STYLE_CALLTIP=38,STYLE_CONTROLCHAR=36,STYLE_DEFAULT=32,STYLE_INDENTGUIDE=37,STYLE_LASTPREDEFINED=39,STYLE_LINENUMBER=33,STYLE_MAX=255,VISIBLE_SLOP=0x01,VISIBLE_STRICT=0x04,SCN_DOUBLECLICK=2006,SCN_AUTOCCHARDELETED=2027,SCN_SAVEPOINTLEFT=2003,SCN_PAINTED=2013,SCN_HOTSPOTRELEASECLICK=2028,SCN_UPDATEUI=2007,SCN_STYLENEEDED=2000,SCN_AUTOCCANCELLED=2026,SCN_MACRORECORD=2009,SCN_INDICATORRELEASE=2024,SCN_MODIFIED=2008,SCN_SAVEPOINTREACHED=2002,SCN_HOTSPOTDOUBLECLICK=2020,SCN_NEEDSHOWN=2011,SCN_CALLTIPCLICK=2021,SCN_AUTOCSELECTION=2022,SCN_DWELLEND=2017,SCN_ZOOM=2018,SCN_CHARADDED=2001,SCN_HOTSPOTCLICK=2019,SCN_KEY=2005,SCN_DWELLSTART=2016,SCN_MARGINCLICK=2010,SCN_USERLISTSELECTION=2014,SCN_URIDROPPED=2015,SCN_INDICATORCLICK=2023,SCN_MODIFYATTEMPTRO=2004,SCLEX_LPEG=999} +M.constants = {ANNOTATION_BOXED=2,ANNOTATION_HIDDEN=0,ANNOTATION_STANDARD=1,CARETSTYLE_BLOCK=2,CARETSTYLE_INVISIBLE=0,CARETSTYLE_LINE=1,CARET_EVEN=0x08,CARET_JUMPS=0x10,CARET_SLOP=0x01,CARET_STRICT=0x04,EDGE_BACKGROUND=2,EDGE_LINE=1,EDGE_NONE=0,INDIC_BOX=6,INDIC_COMPOSITIONTHICK=14,INDIC_CONTAINER=8,INDIC_DASH=9,INDIC_DIAGONAL=3,INDIC_DOTBOX=12,INDIC_DOTS=10,INDIC_HIDDEN=5,INDIC_MAX=31,INDIC_PLAIN=0,INDIC_ROUNDBOX=7,INDIC_SQUIGGLE=1,INDIC_SQUIGGLELOW=11,INDIC_SQUIGGLEPIXMAP=13,INDIC_STRAIGHTBOX=8,INDIC_STRIKE=4,INDIC_TT=2,MARKER_MAX=31,SCFIND_MATCHCASE=4,SCFIND_POSIX=0x00400000,SCFIND_REGEXP=0x00200000,SCFIND_WHOLEWORD=2,SCFIND_WORDSTART=0x00100000,SCMOD_ALT=4,SCMOD_CTRL=2,SCMOD_META=16,SCMOD_NORM=0,SCMOD_SHIFT=1,SCMOD_SUPER=8,SCVS_NONE=0,SCVS_RECTANGULARSELECTION=1,SCVS_USERACCESSIBLE=2,SCWS_INVISIBLE=0,SCWS_VISIBLEAFTERINDENT=2,SCWS_VISIBLEALWAYS=1,ALPHA_NOALPHA=256,ALPHA_OPAQUE=255,ALPHA_TRANSPARENT=0,AUTOMATICFOLD_CHANGE=0x0004,AUTOMATICFOLD_CLICK=0x0002,AUTOMATICFOLD_SHOW=0x0001,CARETSTICKY_OFF=0,CARETSTICKY_ON=1,CARETSTICKY_WHITESPACE=2,CASEINSENSITIVEBEHAVIOUR_IGNORECASE=1,CASEINSENSITIVEBEHAVIOUR_RESPECTCASE=0,CASE_LOWER=2,CASE_MIXED=0,CASE_UPPER=1,CP_UTF8=65001,CURSORARROW=2,CURSORNORMAL=-1,CURSORREVERSEARROW=7,CURSORWAIT=4,EOL_CR=1,EOL_CRLF=0,EOL_LF=2,FOLDACTION_CONTRACT=0,FOLDACTION_EXPAND=1,FOLDACTION_TOGGLE=2,FOLDFLAG_LEVELNUMBERS=0x0040,FOLDFLAG_LINEAFTER_CONTRACTED=0x0010,FOLDFLAG_LINEAFTER_EXPANDED=0x0008,FOLDFLAG_LINEBEFORE_CONTRACTED=0x0004,FOLDFLAG_LINEBEFORE_EXPANDED=0x0002,FOLDLEVELBASE=0x400,FOLDLEVELHEADERFLAG=0x2000,FOLDLEVELNUMBERMASK=0x0FFF,FOLDLEVELWHITEFLAG=0x1000,IV_LOOKBOTH=3,IV_LOOKFORWARD=2,IV_NONE=0,IV_REAL=1,LASTSTEPINUNDOREDO=0x100,MARGINOPTION_NONE=0,MARGINOPTION_SUBLINESELECT=1,MARGIN_BACK=2,MARGIN_FORE=3,MARGIN_NUMBER=1,MARGIN_RTEXT=5,MARGIN_SYMBOL=0,MARGIN_TEXT=4,MARKNUM_FOLDER=30,MARKNUM_FOLDEREND=25,MARKNUM_FOLDERMIDTAIL=27,MARKNUM_FOLDEROPEN=31,MARKNUM_FOLDEROPENMID=26,MARKNUM_FOLDERSUB=29,MARKNUM_FOLDERTAIL=28,MARK_ARROW=2,MARK_ARROWDOWN=6,MARK_ARROWS=24,MARK_AVAILABLE=28,MARK_BACKGROUND=22,MARK_BOXMINUS=14,MARK_BOXMINUSCONNECTED=15,MARK_BOXPLUS=12,MARK_BOXPLUSCONNECTED=13,MARK_CHARACTER=10000,MARK_CIRCLE=0,MARK_CIRCLEMINUS=20,MARK_CIRCLEMINUSCONNECTED=21,MARK_CIRCLEPLUS=18,MARK_CIRCLEPLUSCONNECTED=19,MARK_DOTDOTDOT=23,MARK_EMPTY=5,MARK_FULLRECT=26,MARK_LCORNER=10,MARK_LCORNERCURVE=16,MARK_LEFTRECT=27,MARK_MINUS=7,MARK_PIXMAP=25,MARK_PLUS=8,MARK_RGBAIMAGE=30,MARK_ROUNDRECT=1,MARK_SHORTARROW=4,MARK_SMALLRECT=3,MARK_TCORNER=11,MARK_TCORNERCURVE=17,MARK_UNDERLINE=29,MARK_VLINE=9,MASK_FOLDERS=-33554432,MAX_MARGIN=4,MODEVENTMASKALL=0xFFFFF,MOD_BEFOREDELETE=0x800,MOD_BEFOREINSERT=0x400,MOD_CHANGEANNOTATION=0x20000,MOD_CHANGEFOLD=0x8,MOD_CHANGEINDICATOR=0x4000,MOD_CHANGELINESTATE=0x8000,MOD_CHANGEMARGIN=0x10000,MOD_CHANGEMARKER=0x200,MOD_CHANGESTYLE=0x4,MOD_CONTAINER=0x40000,MOD_DELETETEXT=0x2,MOD_INSERTTEXT=0x1,MOD_LEXERSTATE=0x80000,MULTILINEUNDOREDO=0x1000,MULTIPASTE_EACH=1,MULTIPASTE_ONCE=0,MULTISTEPUNDOREDO=0x80,ORDER_CUSTOM=2,ORDER_PERFORMSORT=1,ORDER_PRESORTED=0,PERFORMED_REDO=0x40,PERFORMED_UNDO=0x20,PERFORMED_USER=0x10,SEL_LINES=2,SEL_RECTANGLE=1,SEL_STREAM=0,SEL_THIN=3,STARTACTION=0x2000,TIME_FOREVER=10000000,UPDATE_CONTENT=0x1,UPDATE_H_SCROLL=0x8,UPDATE_SELECTION=0x2,UPDATE_V_SCROLL=0x4,WRAPINDENT_FIXED=0,WRAPINDENT_INDENT=2,WRAPINDENT_SAME=1,WRAPVISUALFLAGLOC_DEFAULT=0x0000,WRAPVISUALFLAGLOC_END_BY_TEXT=0x0001,WRAPVISUALFLAGLOC_START_BY_TEXT=0x0002,WRAPVISUALFLAG_END=0x0001,WRAPVISUALFLAG_MARGIN=0x0004,WRAPVISUALFLAG_NONE=0x0000,WRAPVISUALFLAG_START=0x0002,WRAP_CHAR=2,WRAP_NONE=0,WRAP_WORD=1,STYLE_BRACEBAD=35,STYLE_BRACELIGHT=34,STYLE_CALLTIP=38,STYLE_CONTROLCHAR=36,STYLE_DEFAULT=32,STYLE_INDENTGUIDE=37,STYLE_LASTPREDEFINED=39,STYLE_LINENUMBER=33,STYLE_MAX=255,VISIBLE_SLOP=0x01,VISIBLE_STRICT=0x04,SCN_DOUBLECLICK=2006,SCN_AUTOCCHARDELETED=2027,SCN_SAVEPOINTLEFT=2003,SCN_PAINTED=2013,SCN_HOTSPOTRELEASECLICK=2028,SCN_UPDATEUI=2007,SCN_STYLENEEDED=2000,SCN_AUTOCCANCELLED=2026,SCN_MACRORECORD=2009,SCN_INDICATORRELEASE=2024,SCN_MODIFIED=2008,SCN_SAVEPOINTREACHED=2002,SCN_HOTSPOTDOUBLECLICK=2020,SCN_NEEDSHOWN=2011,SCN_CALLTIPCLICK=2021,SCN_AUTOCSELECTION=2022,SCN_DWELLEND=2017,SCN_ZOOM=2018,SCN_CHARADDED=2001,SCN_HOTSPOTCLICK=2019,SCN_KEY=2005,SCN_DWELLSTART=2016,SCN_MARGINCLICK=2010,SCN_USERLISTSELECTION=2014,SCN_URIDROPPED=2015,SCN_INDICATORCLICK=2023,SCN_MODIFYATTEMPTRO=2004,SCLEX_LPEG=999} --- -- Map of Scintilla function names to tables containing their IDs, return types, @@ -42,7 +42,7 @@ M.functions = {add_ref_document={2376,0,0,1},add_selection={2573,1,1,1},add_styl -- @name properties M.properties = {additional_caret_fore={2605,2604,4,0},additional_carets_blink={2568,2567,5,0},additional_carets_visible={2609,2608,5,0},additional_sel_alpha={2603,2602,1,0},additional_sel_back={0,2601,4,0},additional_sel_fore={0,2600,4,0},additional_selection_typing={2566,2565,5,0},all_lines_visible={2236,0,5,0},anchor={2009,2026,3,0},annotation_lines={2546,0,1,1},annotation_style={2543,2542,1,1},annotation_style_offset={2551,2550,1,0},annotation_styles={2545,2544,8,1},annotation_text={2541,2540,8,1},annotation_visible={2549,2548,1,0},auto_c_auto_hide={2119,2118,5,0},auto_c_cancel_at_start={2111,2110,5,0},auto_c_case_insensitive_behaviour={2635,2634,1,0},auto_c_choose_single={2114,2113,5,0},auto_c_current={2445,0,1,0},auto_c_current_text={2610,0,8,0},auto_c_drop_rest_of_word={2271,2270,5,0},auto_c_fill_ups={0,2112,7,0},auto_c_ignore_case={2116,2115,5,0},auto_c_max_height={2211,2210,1,0},auto_c_max_width={2209,2208,1,0},auto_c_order={2661,2660,1,0},auto_c_separator={2107,2106,1,0},auto_c_type_separator={2285,2286,1,0},automatic_fold={2664,2663,1,0},back_space_un_indents={2263,2262,5,0},buffered_draw={2034,2035,5,0},call_tip_back={0,2205,4,0},call_tip_fore={0,2206,4,0},call_tip_fore_hlt={0,2207,4,0},call_tip_position={0,2213,5,0},call_tip_use_style={0,2212,1,0},caret_fore={2138,2069,4,0},caret_line_back={2097,2098,4,0},caret_line_back_alpha={2471,2470,1,0},caret_line_visible={2095,2096,5,0},caret_line_visible_always={2654,2655,5,0},caret_period={2075,2076,1,0},caret_sticky={2457,2458,1,0},caret_style={2513,2512,1,0},caret_width={2189,2188,1,0},char_at={2007,0,1,3},character_pointer={2520,0,1,0},code_page={2137,2037,1,0},column={2129,0,1,3},control_char_symbol={2389,2388,1,0},current_pos={2008,2141,3,0},cursor={2387,2386,1,0},direct_function={2184,0,1,0},direct_pointer={2185,0,1,0},distance_to_secondary_styles={4025,0,1,0},doc_pointer={2357,2358,1,0},eol_mode={2030,2031,1,0},edge_colour={2364,2365,4,0},edge_column={2360,2361,1,0},edge_mode={2362,2363,1,0},end_at_last_line={2278,2277,5,0},end_styled={2028,0,3,0},extra_ascent={2526,2525,1,0},extra_descent={2528,2527,1,0},first_visible_line={2152,2613,1,0},focus={2381,2380,5,0},fold_expanded={2230,2229,5,1},fold_flags={0,2233,1,0},fold_level={2223,2222,1,1},fold_parent={2225,0,1,1},font_quality={2612,2611,1,0},gap_position={2644,0,3,0},h_scroll_bar={2131,2130,5,0},highlight_guide={2135,2134,1,0},hotspot_active_underline={2496,2412,5,0},hotspot_single_line={2497,2421,5,0},identifier={2623,2622,1,0},identifiers={0,4024,7,1},indent={2123,2122,1,0},indentation_guides={2133,2132,1,0},indic_alpha={2524,2523,1,1},indic_fore={2083,2082,4,1},indic_outline_alpha={2559,2558,1,1},indic_style={2081,2080,1,1},indic_under={2511,2510,5,1},indicator_current={2501,2500,1,0},indicator_value={2503,2502,1,0},key_words={0,4005,7,1},keys_unicode={2522,2521,5,0},layout_cache={2273,2272,1,0},length={2006,0,1,0},lexer={4002,4001,1,0},lexer_language={4012,4006,8,0},line_count={2154,0,1,0},line_end_position={2136,0,3,1},line_end_types_active={2658,0,1,0},line_end_types_allowed={2657,2656,1,0},line_end_types_supported={4018,0,1,0},line_indent_position={2128,0,3,1},line_indentation={2127,2126,1,1},line_state={2093,2092,1,1},line_visible={2228,0,5,1},lines_on_screen={2370,0,1,0},main_selection={2575,2574,1,0},margin_cursor_n={2249,2248,1,1},margin_left={2156,2155,1,0},margin_mask_n={2245,2244,1,1},margin_options={2557,2539,1,0},margin_right={2158,2157,1,0},margin_sensitive_n={2247,2246,5,1},margin_style={2533,2532,1,1},margin_style_offset={2538,2537,1,0},margin_styles={2535,2534,8,1},margin_text={2531,2530,8,1},margin_type_n={2241,2240,1,1},margin_width_n={2243,2242,1,1},marker_alpha={0,2476,1,1},marker_back={0,2042,4,1},marker_back_selected={0,2292,4,1},marker_fore={0,2041,4,1},max_line_state={2094,0,1,0},mod_event_mask={2378,2359,1,0},modify={2159,0,5,0},mouse_down_captures={2385,2384,5,0},mouse_dwell_time={2265,2264,1,0},multi_paste={2615,2614,1,0},multiple_selection={2564,2563,5,0},overtype={2187,2186,5,0},paste_convert_endings={2468,2467,5,0},position_cache={2515,2514,1,0},print_colour_mode={2149,2148,1,0},print_magnification={2147,2146,1,0},print_wrap_mode={2407,2406,1,0},property={4008,4004,8,7},property_expanded={4009,0,8,7},property_int={4010,0,1,7},punctuation_chars={2649,2648,8,0},rgba_image_height={0,2625,1,0},rgba_image_scale={0,2651,1,0},rgba_image_width={0,2624,1,0},read_only={2140,2171,5,0},rectangular_selection_anchor={2591,2590,3,0},rectangular_selection_anchor_virtual_space={2595,2594,1,0},rectangular_selection_caret={2589,2588,3,0},rectangular_selection_caret_virtual_space={2593,2592,1,0},rectangular_selection_modifier={2599,2598,1,0},scroll_width={2275,2274,1,0},scroll_width_tracking={2517,2516,5,0},search_flags={2199,2198,1,0},sel_alpha={2477,2478,1,0},sel_eol_filled={2479,2480,5,0},selection_empty={2650,0,5,0},selection_end={2145,2144,3,0},selection_is_rectangle={2372,0,5,0},selection_mode={2423,2422,1,0},selection_n_anchor={2579,2578,3,1},selection_n_anchor_virtual_space={2583,2582,1,1},selection_n_caret={2577,2576,3,1},selection_n_caret_virtual_space={2581,2580,1,1},selection_n_end={2587,2586,3,1},selection_n_start={2585,2584,3,1},selection_start={2143,2142,3,0},selections={2570,0,1,0},status={2383,2382,1,0},style_at={2010,0,1,3},style_back={2482,2052,4,1},style_bits={2091,2090,1,0},style_bits_needed={4011,0,1,0},style_bold={2483,2053,5,1},style_case={2489,2060,1,1},style_changeable={2492,2099,5,1},style_character_set={2490,2066,1,1},style_eol_filled={2487,2057,5,1},style_font={2486,2056,8,1},style_fore={2481,2051,4,1},style_hot_spot={2493,2409,5,1},style_italic={2484,2054,5,1},style_size={2485,2055,1,1},style_size_fractional={2062,2061,1,1},style_underline={2488,2059,5,1},style_visible={2491,2074,5,1},style_weight={2064,2063,1,1},sub_style_bases={4026,0,8,0},sub_styles_length={4022,0,1,1},sub_styles_start={4021,0,1,1},tab_indents={2261,2260,5,0},tab_width={2121,2036,1,0},tag={2616,0,8,1},target_end={2193,2192,3,0},target_start={2191,2190,3,0},technology={2631,2630,1,0},text_length={2183,0,1,0},two_phase_draw={2283,2284,5,0},undo_collection={2019,2012,5,0},use_tabs={2125,2124,5,0},v_scroll_bar={2281,2280,5,0},view_eol={2355,2356,5,0},view_ws={2020,2021,1,0},virtual_space_options={2597,2596,1,0},whitespace_chars={2647,2443,8,0},whitespace_size={2087,2086,1,0},word_chars={2646,2077,8,0},wrap_indent_mode={2473,2472,1,0},wrap_mode={2269,2268,1,0},wrap_start_indent={2465,2464,1,0},wrap_visual_flags={2461,2460,1,0},wrap_visual_flags_location={2463,2462,1,0},x_offset={2398,2397,1,0},zoom={2374,2373,1,0}} -local marker_number, indic_number, list_type = -1, 7, 0 +local marker_number, indic_number, list_type = -1, -1, 0 --- -- Returns a unique marker number for use with `buffer.marker_define()`. diff --git a/core/ui.lua b/core/ui.lua index 7f554b76..c007c4f9 100644 --- a/core/ui.lua +++ b/core/ui.lua @@ -52,7 +52,7 @@ local function _print(buffer_type, ...) buffer:set_save_point() end --- --- Helper function for printing messages to the buffer of type *buffer_type*. +-- Prints the given string messages to the buffer of type *buffer_type*. -- Splits the view and opens a new buffer for printing messages to. If the -- message buffer is already open in a view, the message is printed to that -- view. Otherwise the view is split and the message buffer is opened or @@ -64,7 +64,7 @@ end function ui._print(buffer_type, ...) pcall(_print, buffer_type, ...) end --- --- Prints messages to the Textadept message buffer. +-- Prints the given string messages to the message buffer. -- Opens a new buffer if one has not already been opened for printing messages. -- @param ... Message strings. -- @name print @@ -129,8 +129,8 @@ end -- Goes to the buffer whose filename is *filename* in an existing view, -- otherwise splitting the current view if *split* is `true` or going to the -- next or *preferred_view* view instead of staying in the current one. --- If *sloppy* is `true`, only the last part of *filename* is matched to a --- buffer's `filename`. +-- *sloppy* indicates whether or not only the last part of *filename* is matched +-- to a buffer's `filename`. -- @param filename The filename of the buffer to go to. -- @param split Optional flag indicating whether or not to open the buffer in a -- split view if there is only one view. The default value is `false`. @@ -238,7 +238,7 @@ local SETDIRECTPOINTER = _SCINTILLA.properties.doc_pointer[2] local SETLEXERLANGUAGE = _SCINTILLA.properties.lexer_language[2] -- Sets default properties for a Scintilla document. events_connect(events.BUFFER_NEW, function() - buffer.code_page = buffer.SC_CP_UTF8 + buffer.code_page = buffer.CP_UTF8 buffer.style_bits = 8 buffer.lexer_language = 'lpeg' buffer:private_lexer_call(SETDIRECTFUNCTION, buffer.direct_function) @@ -418,8 +418,8 @@ local get_split_table --- -- Goes to view number *n*. --- If *relative* is `true`, *n* is an index relative to the index of the current --- view in `_G._VIEWS` instead of an absolute index. +-- *relative* indicates whether or not *n* is an index relative to the index of +-- the current view in `_G._VIEWS` instead of an absolute index. -- Emits `VIEW_BEFORE_SWITCH` and `VIEW_AFTER_SWITCH` events. -- @param n A relative or absolute view index in `_G._VIEWS`. -- @param relative Optional flag indicating whether *n* is a relative or diff --git a/doc/06_AdeptEditing.md b/doc/06_AdeptEditing.md index 6e26f6c9..2176c39a 100644 --- a/doc/06_AdeptEditing.md +++ b/doc/06_AdeptEditing.md @@ -45,7 +45,7 @@ characters. The caret also changes to an underline in overwrite mode. Textadept includes many ways of creating and working with selections. Creating basic selections entails holding down the "Shift" modifier key while pressing -the arrow keys, clicking and dragging the mouse over a range of text, or +the arrow keys, clicking and dragging the mouse cursor over a range of text, or pressing `Ctrl+A` (`⌘A` | `M-A`) to select all text. Creating more advanced selections like multiple and rectangular selections requires slightly more effort, but has powerful uses. diff --git a/doc/14_Appendix.md b/doc/14_Appendix.md index 144a8602..666f2228 100644 --- a/doc/14_Appendix.md +++ b/doc/14_Appendix.md @@ -120,7 +120,7 @@ non-existant graphics capabilities: corners. * Insert mode caret renders improperly. * When scrolling to the right, long lines overwrite margins. -* No marker symbols other than `SC_MARK_CHARACTER`. +* No marker symbols other than `MARK_CHARACTER`. * No mouse interactions, cursor types, or hotspots. * Only up to 16 colors recognized: black (`0x000000`), red (`0x800000`), green (`0x008000`), yellow (`0x808000`), blue (`0x000080`), magenta (`0x800080`), @@ -179,6 +179,8 @@ N/A |New |[MARK\_ERROR][] MARK\_ERROR\_BACK |Removed |N/A<sup>c</sup> **_M.textadept.snapopen** |Removed |N/A open |Changed |\_G.[io.snapopen()][]<sup>e</sup> +**_SCINTILLA.constants** | | +SC\_\* |Renamed |Removed "SC\_" prefix. **buffer** | | get\_style\_name(buffer, n) |Renamed |[style\_name][]\[n\] reload |Renamed |[io.reload\_file][] diff --git a/doc/markdowndoc.lua b/doc/markdowndoc.lua index ea1ba26a..e8947784 100644 --- a/doc/markdowndoc.lua +++ b/doc/markdowndoc.lua @@ -269,7 +269,6 @@ function M.start(doc) template.toc = template.toc:gsub('(<a.-)%b()(</a>)', '%1%2') -- strip params :gsub('<code>([^<]+)</code>', '%1') -- sans serif :gsub('>rectangular_[%w_]+', '><small%0</small>') - :gsub('>SC_[%u]+', '><small%0</small>') :gsub('>_G.(events.[%w_]+)', '><small>%1</small>') f = io_open(M.options.output_dir..'/api/'..name..'.html', 'wb') diff --git a/modules/textadept/adeptsense.lua b/modules/textadept/adeptsense.lua index 63ee855b..be350c75 100644 --- a/modules/textadept/adeptsense.lua +++ b/modules/textadept/adeptsense.lua @@ -715,10 +715,11 @@ end) --- -- Loads the Ctags file *tag_file* for autocompletions. --- If *nolocations* is `true`, `sense:goto_ctag()` cannot be used with this set --- of tags. It is recommended to pass `-n` to `ctags` in order to use line --- numbers instead of text patterns to locate tags. This will greatly reduce --- memory usage for a large number of symbols if `nolocations` is `false`. +-- *nolocations* indicates whether or not to store the location part of tags. If +-- `true`, `sense:goto_ctag()` cannot be used with this set of tags. It is +-- recommended to pass `-n` to `ctags` in order to use line numbers instead of +-- text patterns to locate tags. This will greatly reduce memory usage for a +-- large number of symbols if *nolocations* is `false`. -- @param sense The Adeptsense returned by `adeptsense.new()`. -- @param tag_file The path of the Ctags file to load. -- @param nolocations Optional flag indicating whether or not to discard the diff --git a/modules/textadept/find.lua b/modules/textadept/find.lua index 0e912367..b4be38b5 100644 --- a/modules/textadept/find.lua +++ b/modules/textadept/find.lua @@ -188,8 +188,8 @@ end -- Begins an incremental search using the command entry if *text* is `nil`; -- otherwise continues an incremental search by searching for the next or -- previous instance of string *text* depending on boolean *next*. --- If *anchor* is `true`, searches for *text* starting from the current position --- instead of the position where incremental search began at. +-- *anchor* indicates whether or not to search for *text* starting from the +-- current position instead of the position where incremental search began at. -- Only the `match_case` find option is recognized. Normal command entry -- functionality is unavailable until the search is finished by pressing `Esc` -- (`⎋` on Mac OSX | `Esc` in curses). diff --git a/modules/textadept/keys.lua b/modules/textadept/keys.lua index f7cb599b..c140c095 100644 --- a/modules/textadept/keys.lua +++ b/modules/textadept/keys.lua @@ -511,9 +511,9 @@ if CURSES then keys.mT = keys.mt end -- in case mt is used by GUI terminals keys[not OSX and (not CURSES and 'cai' or 'mi') or 'ci'] = editing.convert_indentation -- EOL Mode. --- TODO: {utils.set_eol_mode, buffer.SC_EOL_CRLF} --- TODO: {utils.set_eol_mode, buffer.SC_EOL_CR} --- TODO: {utils.set_eol_mode, buffer.SC_EOL_LF} +-- TODO: {utils.set_eol_mode, buffer.EOL_CRLF} +-- TODO: {utils.set_eol_mode, buffer.EOL_CR} +-- TODO: {utils.set_eol_mode, buffer.EOL_LF} -- Encoding. -- TODO: {utils.set_encoding, 'UTF-8'} -- TODO: {utils.set_encoding, 'ASCII'} diff --git a/modules/textadept/menu.lua b/modules/textadept/menu.lua index af8e7550..fbb74499 100644 --- a/modules/textadept/menu.lua +++ b/modules/textadept/menu.lua @@ -145,9 +145,9 @@ local menubar = { {_L['_Convert Indentation'], editing.convert_indentation}, }, { title = _L['_EOL Mode'], - {_L['CRLF'], {utils.set_eol_mode, buffer.SC_EOL_CRLF}}, - {_L['CR'], {utils.set_eol_mode, buffer.SC_EOL_CR}}, - {_L['LF'], {utils.set_eol_mode, buffer.SC_EOL_LF}}, + {_L['CRLF'], {utils.set_eol_mode, buffer.EOL_CRLF}}, + {_L['CR'], {utils.set_eol_mode, buffer.EOL_CR}}, + {_L['LF'], {utils.set_eol_mode, buffer.EOL_LF}}, }, { title = _L['E_ncoding'], {_L['_UTF-8 Encoding'], {utils.set_encoding, 'UTF-8'}}, diff --git a/modules/textadept/snippets.lua b/modules/textadept/snippets.lua index 9b8e8bda..6a664792 100644 --- a/modules/textadept/snippets.lua +++ b/modules/textadept/snippets.lua @@ -48,7 +48,7 @@ local M = {} -- -- Textadept runs Lua code in its Lua State and replaces the transform with the -- code's return text. The code may use a temporary `selected_text` global --- variable that contains the current selection in the buffer. An example is +-- variable that contains the currently selected text. An example is -- -- snippets['foo'] = [[ -- %2<('%1'):gsub('^.', function(c) @@ -364,8 +364,7 @@ M._snippet_mt = { buffer.indicator_current = INDIC_SNIPPET e = snippet:get_end_position() buffer:indicator_clear_range(e, 1) - buffer.target_start, buffer.target_end = e, e + 1 - buffer:replace_target('') -- clear initial padding space + buffer:delete_range(e, 1) -- clear initial padding space snippet_stack[#snippet_stack] = nil end, } diff --git a/properties.lua b/properties.lua index 9d47ff0d..74946ac4 100644 --- a/properties.lua +++ b/properties.lua @@ -5,7 +5,7 @@ local buffer = buffer -- Multiple Selection and Virtual Space buffer.multiple_selection = true buffer.additional_selection_typing = true ---buffer.multi_paste = buffer.SC_MULTIPASTE_EACH +--buffer.multi_paste = buffer.MULTIPASTE_EACH --buffer.virtual_space_options = buffer.SCVS_RECTANGULARSELECTION + -- buffer.SCVS_USERACCESSIBLE buffer.rectangular_selection_modifier = (WIN32 or OSX) and buffer.SCMOD_ALT or @@ -40,7 +40,7 @@ buffer.caret_line_visible_always = true --buffer.caret_period = 0 --buffer.caret_style = buffer.CARETSTYLE_BLOCK --buffer.caret_width = ---buffer.caret_sticky = buffer.SC_CARETSTICKY_ON +--buffer.caret_sticky = buffer.CARETSTICKY_ON -- Margins. --buffer.margin_left = @@ -51,12 +51,12 @@ buffer.margin_width_n[0] = width + (not CURSES and 4 or 0) -- Marker Margin. buffer.margin_width_n[1] = not CURSES and 12 or 1 buffer.margin_sensitive_n[1] = true -buffer.margin_cursor_n[1] = buffer.SC_CURSORARROW +buffer.margin_cursor_n[1] = buffer.CURSORARROW -- Fold Margin. buffer.margin_width_n[2] = not CURSES and 12 or 1 -buffer.margin_mask_n[2] = buffer.SC_MASK_FOLDERS +buffer.margin_mask_n[2] = buffer.MASK_FOLDERS buffer.margin_sensitive_n[2] = true -buffer.margin_cursor_n[2] = buffer.SC_CURSORARROW +buffer.margin_cursor_n[2] = buffer.CURSORARROW -- Annotations. buffer.annotation_visible = buffer.ANNOTATION_BOXED @@ -75,53 +75,49 @@ buffer.use_tabs = false --buffer.indent = 2 buffer.tab_indents = true buffer.back_space_un_indents = true -buffer.indentation_guides = buffer.SC_IV_LOOKBOTH +buffer.indentation_guides = buffer.IV_LOOKBOTH -- Margin Markers. -local symbol = not CURSES and buffer.SC_MARK_SMALLRECT or - buffer.SC_MARK_CHARACTER + string.byte(' ') +local symbol = not CURSES and buffer.MARK_SMALLRECT or + buffer.MARK_CHARACTER + string.byte(' ') buffer:marker_define(textadept.bookmarks.MARK_BOOKMARK, symbol) buffer:marker_define(textadept.run.MARK_ERROR, symbol) if not CURSES then -- Arrow Folding Symbols. --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPEN, buffer.SC_MARK_ARROWDOWN) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDER, buffer.SC_MARK_ARROW) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERSUB, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERTAIL, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEREND, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPENMID, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERMIDTAIL, buffer.SC_MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPEN, buffer.MARK_ARROWDOWN) +-- buffer:marker_define(buffer.MARKNUM_FOLDER, buffer.MARK_ARROW) +-- buffer:marker_define(buffer.MARKNUM_FOLDERSUB, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDERTAIL, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEREND, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPENMID, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDERMIDTAIL, buffer.MARK_EMPTY) -- Plus/Minus Folding Symbols. --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPEN, buffer.SC_MARK_MINUS) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDER, buffer.SC_MARK_PLUS) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERSUB, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERTAIL, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEREND, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPENMID, buffer.SC_MARK_EMPTY) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERMIDTAIL, buffer.SC_MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPEN, buffer.MARK_MINUS) +-- buffer:marker_define(buffer.MARKNUM_FOLDER, buffer.MARK_PLUS) +-- buffer:marker_define(buffer.MARKNUM_FOLDERSUB, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDERTAIL, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEREND, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPENMID, buffer.MARK_EMPTY) +-- buffer:marker_define(buffer.MARKNUM_FOLDERMIDTAIL, buffer.MARK_EMPTY) -- Circle Tree Folding Symbols. --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPEN, --- buffer.SC_MARK_CIRCLEMINUS) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDER, buffer.SC_MARK_CIRCLEPLUS) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERSUB, buffer.SC_MARK_VLINE) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERTAIL, --- buffer.SC_MARK_LCORNERCURVE) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEREND, --- buffer.SC_MARK_CIRCLEPLUSCONNECTED) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPENMID, --- buffer.SC_MARK_CIRCLEMINUSCONNECTED) --- buffer:marker_define(buffer.SC_MARKNUM_FOLDERMIDTAIL, --- buffer.SC_MARK_TCORNERCURVE) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPEN, buffer.MARK_CIRCLEMINUS) +-- buffer:marker_define(buffer.MARKNUM_FOLDER, buffer.MARK_CIRCLEPLUS) +-- buffer:marker_define(buffer.MARKNUM_FOLDERSUB, buffer.MARK_VLINE) +-- buffer:marker_define(buffer.MARKNUM_FOLDERTAIL, buffer.MARK_LCORNERCURVE) +-- buffer:marker_define(buffer.MARKNUM_FOLDEREND, +-- buffer.MARK_CIRCLEPLUSCONNECTED) +-- buffer:marker_define(buffer.MARKNUM_FOLDEROPENMID, +-- buffer.MARK_CIRCLEMINUSCONNECTED) +-- buffer:marker_define(buffer.MARKNUM_FOLDERMIDTAIL, buffer.MARK_TCORNERCURVE) -- Box Tree Folding Symbols. - buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPEN, buffer.SC_MARK_BOXMINUS) - buffer:marker_define(buffer.SC_MARKNUM_FOLDER, buffer.SC_MARK_BOXPLUS) - buffer:marker_define(buffer.SC_MARKNUM_FOLDERSUB, buffer.SC_MARK_VLINE) - buffer:marker_define(buffer.SC_MARKNUM_FOLDERTAIL, buffer.SC_MARK_LCORNER) - buffer:marker_define(buffer.SC_MARKNUM_FOLDEREND, - buffer.SC_MARK_BOXPLUSCONNECTED) - buffer:marker_define(buffer.SC_MARKNUM_FOLDEROPENMID, - buffer.SC_MARK_BOXMINUSCONNECTED) - buffer:marker_define(buffer.SC_MARKNUM_FOLDERMIDTAIL, buffer.SC_MARK_TCORNER) + buffer:marker_define(buffer.MARKNUM_FOLDEROPEN, buffer.MARK_BOXMINUS) + buffer:marker_define(buffer.MARKNUM_FOLDER, buffer.MARK_BOXPLUS) + buffer:marker_define(buffer.MARKNUM_FOLDERSUB, buffer.MARK_VLINE) + buffer:marker_define(buffer.MARKNUM_FOLDERTAIL, buffer.MARK_LCORNER) + buffer:marker_define(buffer.MARKNUM_FOLDEREND, buffer.MARK_BOXPLUSCONNECTED) + buffer:marker_define(buffer.MARKNUM_FOLDEROPENMID, + buffer.MARK_BOXMINUSCONNECTED) + buffer:marker_define(buffer.MARKNUM_FOLDERMIDTAIL, buffer.MARK_TCORNER) end --buffer:marker_enable_highlight(true) @@ -137,7 +133,7 @@ end buffer.auto_c_choose_single = true --buffer.auto_c_ignore_case = true --buffer.auto_c_case_insensitive_behaviour = --- buffer.SC_CASEINSENSITIVEBEHAVIOUR_IGNORECASE +-- buffer.CASEINSENSITIVEBEHAVIOUR_IGNORECASE --buffer.auto_c_auto_hide = false --buffer.auto_c_drop_rest_of_word = true --buffer.auto_c_max_height = @@ -152,16 +148,15 @@ buffer.call_tip_use_style = buffer.tab_width * buffer.property['fold'] = '1' buffer.property['fold.by.indentation'] = '0' buffer.property['fold.line.comments'] = '0' -buffer.automatic_fold = buffer.SC_AUTOMATICFOLD_SHOW + - buffer.SC_AUTOMATICFOLD_CLICK + - buffer.SC_AUTOMATICFOLD_CHANGE -buffer.fold_flags = not CURSES and buffer.SC_FOLDFLAG_LINEAFTER_CONTRACTED or 0 +buffer.automatic_fold = buffer.AUTOMATICFOLD_SHOW + buffer.AUTOMATICFOLD_CLICK + + buffer.AUTOMATICFOLD_CHANGE +buffer.fold_flags = not CURSES and buffer.FOLDFLAG_LINEAFTER_CONTRACTED or 0 -- Line Wrapping. ---buffer.wrap_mode = buffer.SC_WRAP_WORD ---buffer.wrap_visual_flags = buffer.SC_WRAPVISUALFLAG_MARGIN ---buffer.wrap_visual_flags_location = buffer.SC_WRAPVISUALFLAGLOC_END_BY_TEXT ---buffer.wrap_indent_mode = buffer.SC_WRAPINDENT_SAME +--buffer.wrap_mode = buffer.WRAP_WORD +--buffer.wrap_visual_flags = buffer.WRAPVISUALFLAG_MARGIN +--buffer.wrap_visual_flags_location = buffer.WRAPVISUALFLAGLOC_END_BY_TEXT +--buffer.wrap_indent_mode = buffer.WRAPINDENT_SAME --buffer.wrap_start_indent = -- Long Lines. diff --git a/scripts/gen_iface.lua b/scripts/gen_iface.lua index 05ef080e..6fa49cc0 100755 --- a/scripts/gen_iface.lua +++ b/scripts/gen_iface.lua @@ -39,7 +39,7 @@ local ignores = { '^SC_CACHE_', '^SC_CHARSET_', '^SC_EFF_', '^SC_FONT_SIZE_MULTIPLIER', '^SC_LINE_END_TYPE_', -- provisional '^SC_PRINT_', '^SC_STATUS_', '^SC_TECHNOLOGY_', '^SC_TYPE_', '^SC_WEIGHT_', - '^SCE_', '^SCEN_', '^SCI_', '^SCLEX_', + '^SCE_', '^SCEN_', '^SCI_', '^SCK_', '^SCLEX_', '^UNDO_MAY_COALESCE' } -- Constants ({"constant", value}). @@ -48,7 +48,8 @@ for item in iface:match('Constants%[%] = (%b{})'):sub(2, -2):gmatch('%b{}') do local skip = false for i = 1, #ignores do if name:find(ignores[i]) then skip = true break end end if not skip then - if name == 'SC_MASK_FOLDERS' then value = '-33554432' end + name = name:gsub('SC_', '') + if name == 'MASK_FOLDERS' then value = '-33554432' end constants[#constants + 1] = string_format('%s=%s', name, value) fielddoc[#fielddoc + 1] = string_format('-- * `%s.%s` %d', s, name, value) end |