From 1f5a3b0b2d81351819ebb189a1ae4379e8762e75 Mon Sep 17 00:00:00 2001 From: Neil Date: Wed, 28 Apr 2021 19:20:12 +1000 Subject: Character indices are no longer provisional so move out of Provisional category. --- doc/ScintillaDoc.html | 13 +++++-------- include/Scintilla.h | 16 ++++++++-------- include/Scintilla.iface | 40 ++++++++++++++++++++-------------------- 3 files changed, 33 insertions(+), 36 deletions(-) diff --git a/doc/ScintillaDoc.html b/doc/ScintillaDoc.html index 97b0b965b..32a87bb41 100644 --- a/doc/ScintillaDoc.html +++ b/doc/ScintillaDoc.html @@ -6371,7 +6371,7 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){ SC_DOCUMENTOPTION_STYLES_NONE (0x1) stops allocation of memory to style characters which saves significant memory, often 40% with the whole document treated as being style 0. Lexers may still produce visual styling by using indicators. - SC_DOCUMENTOPTION_TEXT_LARGE (0x100) accomodates documents larger than 2 GigaBytes + SC_DOCUMENTOPTION_TEXT_LARGE (0x100) accomodates documents larger than 2 GigaBytes in 64-bit executables.

@@ -6380,12 +6380,9 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){ Its often more efficient to set the null lexer NULL so no lexer is run.

-

The SC_DOCUMENTOPTION_TEXT_LARGE option is experimental and has not been - thoroughly tested. Lexers may fail or hang when lexing past 2GB or 4GB. - Applications using this option should be tested to ensure the option works in their circumstances and each lexer - included should also be tested with documents larger than 4GB. - For many applications lexing documents larger than 4GB will be too sluggish so SC_DOCUMENTOPTION_STYLES_NONE - and the null lexer NULL can be used. Another approach is to turn on idle styling with +

For many applications lexing documents larger than 4GB will be too sluggish so + SC_DOCUMENTOPTION_STYLES_NONE + and the null lexer "null" can be used. Another approach is to turn on idle styling with SCI_SETIDLESTYLING.

@@ -6413,7 +6410,7 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){ - SC_DOCUMENTOPTION_TEXT_LARGE + SC_DOCUMENTOPTION_TEXT_LARGE 0x100 Allow document to be larger than 2 GB. diff --git a/include/Scintilla.h b/include/Scintilla.h index ca512ab71..3f16dffc5 100644 --- a/include/Scintilla.h +++ b/include/Scintilla.h @@ -1050,6 +1050,14 @@ typedef sptr_t (*SciFnDirect)(sptr_t ptr, unsigned int iMessage, uptr_t wParam, #define SC_SUPPORTS_TRANSLUCENT_STROKE 3 #define SC_SUPPORTS_PIXEL_MODIFICATION 4 #define SCI_SUPPORTSFEATURE 2750 +#define SC_LINECHARACTERINDEX_NONE 0 +#define SC_LINECHARACTERINDEX_UTF32 1 +#define SC_LINECHARACTERINDEX_UTF16 2 +#define SCI_GETLINECHARACTERINDEX 2710 +#define SCI_ALLOCATELINECHARACTERINDEX 2711 +#define SCI_RELEASELINECHARACTERINDEX 2712 +#define SCI_LINEFROMINDEXPOSITION 2713 +#define SCI_INDEXPOSITIONFROMLINE 2714 #define SCI_STARTRECORD 3001 #define SCI_STOPRECORD 3002 #define SCI_GETLEXER 4002 @@ -1188,14 +1196,6 @@ typedef sptr_t (*SciFnDirect)(sptr_t ptr, unsigned int iMessage, uptr_t wParam, #define SC_BIDIRECTIONAL_R2L 2 #define SCI_GETBIDIRECTIONAL 2708 #define SCI_SETBIDIRECTIONAL 2709 -#define SC_LINECHARACTERINDEX_NONE 0 -#define SC_LINECHARACTERINDEX_UTF32 1 -#define SC_LINECHARACTERINDEX_UTF16 2 -#define SCI_GETLINECHARACTERINDEX 2710 -#define SCI_ALLOCATELINECHARACTERINDEX 2711 -#define SCI_RELEASELINECHARACTERINDEX 2712 -#define SCI_LINEFROMINDEXPOSITION 2713 -#define SCI_INDEXPOSITIONFROMLINE 2714 #endif /* --Autogenerated -- end of section automatically generated from Scintilla.iface */ diff --git a/include/Scintilla.iface b/include/Scintilla.iface index 16f713b45..faf846dc8 100644 --- a/include/Scintilla.iface +++ b/include/Scintilla.iface @@ -2942,6 +2942,26 @@ val SC_SUPPORTS_PIXEL_MODIFICATION=4 # Get whether a feature is supported get bool SupportsFeature=2750(Supports feature,) +enu LineCharacterIndexType=SC_LINECHARACTERINDEX_ +val SC_LINECHARACTERINDEX_NONE=0 +val SC_LINECHARACTERINDEX_UTF32=1 +val SC_LINECHARACTERINDEX_UTF16=2 + +# Retrieve line character index state. +get LineCharacterIndexType GetLineCharacterIndex=2710(,) + +# Request line character index be created or its use count increased. +fun void AllocateLineCharacterIndex=2711(LineCharacterIndexType lineCharacterIndex,) + +# Decrease use count of line character index and remove if 0. +fun void ReleaseLineCharacterIndex=2712(LineCharacterIndexType lineCharacterIndex,) + +# Retrieve the document line containing a position measured in index units. +fun line LineFromIndexPosition=2713(position pos, LineCharacterIndexType lineCharacterIndex) + +# Retrieve the position measured in index units at the start of a document line. +fun position IndexPositionFromLine=2714(line line, LineCharacterIndexType lineCharacterIndex) + # Start notifying the container of all key presses and commands. fun void StartRecord=3001(,) @@ -3225,26 +3245,6 @@ get Bidirectional GetBidirectional=2708(,) # Set bidirectional text display state. set void SetBidirectional=2709(Bidirectional bidirectional,) -enu LineCharacterIndexType=SC_LINECHARACTERINDEX_ -val SC_LINECHARACTERINDEX_NONE=0 -val SC_LINECHARACTERINDEX_UTF32=1 -val SC_LINECHARACTERINDEX_UTF16=2 - -# Retrieve line character index state. -get LineCharacterIndexType GetLineCharacterIndex=2710(,) - -# Request line character index be created or its use count increased. -fun void AllocateLineCharacterIndex=2711(LineCharacterIndexType lineCharacterIndex,) - -# Decrease use count of line character index and remove if 0. -fun void ReleaseLineCharacterIndex=2712(LineCharacterIndexType lineCharacterIndex,) - -# Retrieve the document line containing a position measured in index units. -fun line LineFromIndexPosition=2713(position pos, LineCharacterIndexType lineCharacterIndex) - -# Retrieve the position measured in index units at the start of a document line. -fun position IndexPositionFromLine=2714(line line, LineCharacterIndexType lineCharacterIndex) - cat Deprecated # Divide each styling byte into lexical class bits (default: 5) and indicator -- cgit v1.2.3