aboutsummaryrefslogtreecommitdiffhomepage
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/ScintillaDoc.html49
-rw-r--r--doc/ScintillaHistory.html4
2 files changed, 42 insertions, 11 deletions
diff --git a/doc/ScintillaDoc.html b/doc/ScintillaDoc.html
index 25e7ca15b..d9f658814 100644
--- a/doc/ScintillaDoc.html
+++ b/doc/ScintillaDoc.html
@@ -119,7 +119,7 @@
<h1>Scintilla Documentation</h1>
- <p>Last edited 1 February 2018 NH</p>
+ <p>Last edited 17 April 2018 NH</p>
<p>There is <a class="jump" href="Design.html">an overview of the internal design of
Scintilla</a>.<br />
@@ -5711,11 +5711,12 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
<code><a class="message" href="#SCI_GETDOCPOINTER">SCI_GETDOCPOINTER &rarr; document *</a><br />
<a class="message" href="#SCI_SETDOCPOINTER">SCI_SETDOCPOINTER(&lt;unused&gt;, document
*doc)</a><br />
- <a class="message" href="#SCI_CREATEDOCUMENT">SCI_CREATEDOCUMENT(int bytes, int documentOption) &rarr; document *</a><br />
+ <a class="message" href="#SCI_CREATEDOCUMENT">SCI_CREATEDOCUMENT(int bytes, int documentOptions) &rarr; document *</a><br />
<a class="message" href="#SCI_ADDREFDOCUMENT">SCI_ADDREFDOCUMENT(&lt;unused&gt;, document
*doc)</a><br />
<a class="message" href="#SCI_RELEASEDOCUMENT">SCI_RELEASEDOCUMENT(&lt;unused&gt;, document
*doc)</a><br />
+ <a class="message" href="#SCI_GETDOCUMENTOPTIONS">SCI_GETDOCUMENTOPTIONS &rarr; int</a><br />
</code>
<p><b id="SCI_GETDOCPOINTER">SCI_GETDOCPOINTER &rarr; document *</b><br />
@@ -5732,7 +5733,7 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
window.<br />
6. If <code class="parameter">doc</code> was not 0, its reference count is increased by 1.</p>
- <p><b id="SCI_CREATEDOCUMENT">SCI_CREATEDOCUMENT(int bytes, int documentOption) &rarr; document *</b><br />
+ <p><b id="SCI_CREATEDOCUMENT">SCI_CREATEDOCUMENT(int bytes, int documentOptions) &rarr; document *</b><br />
This message creates a new, empty document and returns a pointer to it. This document is not
selected into the editor and starts with a reference count of 1. This means that you have
ownership of it and must either reduce its reference count by 1 after using
@@ -5743,12 +5744,29 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
to allocate once rather than rely on the buffer growing as data is added.
If <code>SCI_CREATEDOCUMENT</code> fails then 0 is returned.</p>
- <p id="documentOption">The <code class="parameter">documentOption</code> argument
+ <p id="documentOptions">The <code class="parameter">documentOptions</code> argument
chooses between different document capabilities which affect memory allocation and performance with
<code>SC_DOCUMENTOPTION_DEFAULT</code> (0) choosing standard options.
- <code>SC_DOCUMENTOPTION_STYLES_NONE</code> (1) stops allocation of memory to style characters
+ <code>SC_DOCUMENTOPTION_STYLES_NONE</code> (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.</p>
+ Lexers may still produce visual styling by using indicators.
+ <span class="provisional"><code>SC_DOCUMENTOPTION_TEXT_LARGE</code> (0x100) accomodates documents larger than 2 GigaBytes
+ in 64-bit executables.</span>
+ </p>
+
+ <p>With <code>SC_DOCUMENTOPTION_STYLES_NONE</code>, lexers are still active and may display
+ indicators. Some may produce folding information althoough most require lexical styles to correctly determine folding.
+ Its often more efficient to set the null lexer <code>SCLEX_NULL</code> so no lexer is run.
+ </p>
+
+ <p class="provisional">The <code>SC_DOCUMENTOPTION_TEXT_LARGE</code> 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 <code>SC_DOCUMENTOPTION_STYLES_NONE</code>
+ and the null lexer <code>SCLEX_NULL</code> can be used. Another approach is to turn on idle styling with
+ <a class="seealso" href="#SCI_SETIDLESTYLING"><code>SCI_SETIDLESTYLING</code></a>.
+ </p>
<table class="standard" summary="Document options">
<tbody>
@@ -5769,10 +5787,16 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
<tr>
<td align="left">SC_DOCUMENTOPTION_STYLES_NONE</td>
- <td align="left">1</td>
+ <td align="left">0x1</td>
<td align="left">Stop allocation of memory for styles and treat all text as style 0.</td>
</tr>
+ <tr>
+ <td align="left" class="provisional">SC_DOCUMENTOPTION_TEXT_LARGE</td>
+ <td align="left">0x100</td>
+ <td align="left">Allow document to be larger than 2 GB.</td>
+ </tr>
+
</tbody>
</table>
@@ -5794,6 +5818,9 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
world spinning in its orbit you must balance each call to <code>SCI_CREATEDOCUMENT</code> or
<code>SCI_ADDREFDOCUMENT</code> with a call to <code>SCI_RELEASEDOCUMENT</code>.</p>
+ <p><b id="SCI_GETDOCUMENTOPTIONS">SCI_GETDOCUMENTOPTIONS &rarr; int</b><br />
+ Returns the options that were used to create the document.</p>
+
<h2 id="BackgroundLoadSave">Background loading and saving</h2>
<p>To ensure a responsive user interface, applications may decide to load and save documents using a separate thread
@@ -5801,7 +5828,7 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
<h3 id="BackgroundLoad">Loading in the background</h3>
- <code><a class="message" href="#SCI_CREATELOADER">SCI_CREATELOADER(int bytes, int documentOption) &rarr; int</a><br />
+ <code><a class="message" href="#SCI_CREATELOADER">SCI_CREATELOADER(int bytes, int documentOptions) &rarr; int</a><br />
</code>
<p>An application can load all of a file into a buffer it allocates on a background thread and then add the data in that buffer
@@ -5810,15 +5837,15 @@ sptr_t CallScintilla(unsigned int iMessage, uptr_t wParam, sptr_t lParam){
<p>To avoid these issues, a loader object may be created and used to load the file. The loader object supports the ILoader interface.</p>
- <p><b id="SCI_CREATELOADER">SCI_CREATELOADER(int bytes, int documentOption) &rarr; int</b><br />
+ <p><b id="SCI_CREATELOADER">SCI_CREATELOADER(int bytes, int documentOptions) &rarr; int</b><br />
Create an object that supports the <code>ILoader</code> interface which can be used to load data and then
be turned into a Scintilla document object for attachment to a view object.
The <code class="parameter">bytes</code> argument determines the initial memory allocation for the document as it is more efficient
to allocate once rather than rely on the buffer growing as data is added.
If <code>SCI_CREATELOADER</code> fails then 0 is returned.</p>
- <p>The <code class="parameter">documentOption</code> argument
- is described in the <a class="seealso" href="#documentOption"><code>SCI_CREATEDOCUMENT</code></a> section.</p>
+ <p>The <code class="parameter">documentOptions</code> argument
+ is described in the <a class="seealso" href="#documentOptions"><code>SCI_CREATEDOCUMENT</code></a> section.</p>
<h4>ILoader</h4>
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html
index 87bfa49ab..00fe782fe 100644
--- a/doc/ScintillaHistory.html
+++ b/doc/ScintillaHistory.html
@@ -542,6 +542,10 @@
Released 10 April 2018.
</li>
<li>
+ Add experimental SC_DOCUMENTOPTION_TEXT_LARGE option to accomodate documents larger than
+ 2 GigaBytes.
+ </li>
+ <li>
Set the last X chosen when SCI_REPLACESEL called to ensure macros work
when text insertion followed by caret up or down.
</li>