From 2603f1e2074b0f880886b533ffc47ecef4fd33f7 Mon Sep 17 00:00:00 2001 From: Neil Date: Thu, 2 Oct 2014 18:17:13 +1000 Subject: Allow using C++11 for searches as a provisional feature. --- doc/ScintillaDoc.html | 30 +++++++++++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) (limited to 'doc/ScintillaDoc.html') diff --git a/doc/ScintillaDoc.html b/doc/ScintillaDoc.html index 52225cc26..04528b35e 100644 --- a/doc/ScintillaDoc.html +++ b/doc/ScintillaDoc.html @@ -606,8 +606,11 @@ struct Sci_TextRange {

Searching

- There are methods to search for text and for regular expressions. The regular expression support - is limited and should only be used for simple cases and initial development. A different regular expression + There are methods to search for text and for regular expressions. The base regular expression support + is limited and should only be used for simple cases and initial development. + When using a C++11 compliant compiler and runtime, it may be possible to use the + runtime's implementation of <regex> by compiling Scintilla with CXX11_REGEX defined. + A different regular expression library can be integrated into Scintilla or can be called from the container using direct access to the buffer contents through SCI_GETCHARACTERPOINTER. @@ -658,6 +661,17 @@ struct Sci_TextRange { Treat regular expression in a more POSIX compatible manner by interpreting bare ( and ) for tagged sections rather than \( and \). + + SCFIND_CXX11REGEX + + When compiled with CXX11_REGEX this flag + may be set to use <regex> instead of Scintilla's basic regular expressions. + If the regular expression is invalid then -1 is returned and status is set to + SC_STATUS_WARN_REGEX. + The ECMAScript flag is set on the regex object and UTF-8 documents will exhibit Unicode-compliant + behaviour. For MSVC, where wchar_t is 16-bits, the reular expression ".." will match a single + astral-plane character. There may be other differences between compilers. + @@ -971,6 +985,8 @@ struct Sci_TextToFind { If an error occurs, Scintilla may set an internal error number that can be retrieved with SCI_GETSTATUS. To clear the error status call SCI_SETSTATUS(0). + Status values from 1 to 999 are errors and status SC_STATUS_WARN_START (1000) + and above are warnings. The currently defined statuses are:

@@ -988,12 +1004,18 @@ struct Sci_TextToFind { Generic failure - + SC_STATUS_BADALLOC 2 Memory is exhausted + + SC_STATUS_WARN_REGEX + 1001 + Regular expression is invalid + + @@ -7433,6 +7455,8 @@ for line = lineStart to lineEnd do SCI_ENSUREVISIBLE(line) next The SC_TECHNOLOGY_DIRECTWRITERETAIN value for SCI_SETTECHNOLOGY is provisional.

+

Using C++11 <regex> is provisional.

+

Some developers may want to only use features that are stable and have graduated from provisional status. To avoid using provisional messages compile with the symbol SCI_DISABLE_PROVISIONAL defined.

-- cgit v1.2.3