diff options
author | Neil <nyamatongwe@gmail.com> | 2015-07-25 11:25:56 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2015-07-25 11:25:56 +1000 |
commit | 2f2dfccd799599295329f90c17998feabff132e9 (patch) | |
tree | 88a8dade901c0d4118c272ecb5aa971e46015f4c /lexlib | |
parent | a334de1ef14e92748fe3e07cb4b8bb0401e69d07 (diff) | |
download | scintilla-mirror-2f2dfccd799599295329f90c17998feabff132e9.tar.gz |
Use Sci_PositionU/Sci_Position for arguments to functional lexers, folders, and
comment recognizers to allow for future implementation of 64-bit positions.
Diffstat (limited to 'lexlib')
-rw-r--r-- | lexlib/Accessor.h | 2 | ||||
-rw-r--r-- | lexlib/LexerModule.cxx | 4 | ||||
-rw-r--r-- | lexlib/LexerModule.h | 6 | ||||
-rw-r--r-- | lexlib/LexerNoExceptions.h | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/lexlib/Accessor.h b/lexlib/Accessor.h index 1bb86c53b..7a58785f3 100644 --- a/lexlib/Accessor.h +++ b/lexlib/Accessor.h @@ -18,7 +18,7 @@ class Accessor; class WordList; class PropSetSimple; -typedef bool (*PFNIsCommentLeader)(Accessor &styler, int pos, int len); +typedef bool(*PFNIsCommentLeader)(Accessor &styler, Sci_Position pos, Sci_Position len); class Accessor : public LexAccessor { public: diff --git a/lexlib/LexerModule.cxx b/lexlib/LexerModule.cxx index 6cefbee77..aab868a41 100644 --- a/lexlib/LexerModule.cxx +++ b/lexlib/LexerModule.cxx @@ -85,13 +85,13 @@ ILexer *LexerModule::Create() const { return new LexerSimple(this); } -void LexerModule::Lex(unsigned int startPos, int lengthDoc, int initStyle, +void LexerModule::Lex(Sci_PositionU startPos, Sci_Position lengthDoc, int initStyle, WordList *keywordlists[], Accessor &styler) const { if (fnLexer) fnLexer(startPos, lengthDoc, initStyle, keywordlists, styler); } -void LexerModule::Fold(unsigned int startPos, int lengthDoc, int initStyle, +void LexerModule::Fold(Sci_PositionU startPos, Sci_Position lengthDoc, int initStyle, WordList *keywordlists[], Accessor &styler) const { if (fnFolder) { int lineCurrent = styler.GetLine(startPos); diff --git a/lexlib/LexerModule.h b/lexlib/LexerModule.h index 5993c0fe9..3ca978a53 100644 --- a/lexlib/LexerModule.h +++ b/lexlib/LexerModule.h @@ -15,7 +15,7 @@ namespace Scintilla { class Accessor; class WordList; -typedef void (*LexerFunction)(unsigned int startPos, int lengthDoc, int initStyle, +typedef void(*LexerFunction)(Sci_PositionU startPos, Sci_Position lengthDoc, int initStyle, WordList *keywordlists[], Accessor &styler); typedef ILexer *(*LexerFactoryFunction)(); @@ -53,9 +53,9 @@ public: ILexer *Create() const; - virtual void Lex(unsigned int startPos, int length, int initStyle, + virtual void Lex(Sci_PositionU startPos, Sci_Position length, int initStyle, WordList *keywordlists[], Accessor &styler) const; - virtual void Fold(unsigned int startPos, int length, int initStyle, + virtual void Fold(Sci_PositionU startPos, Sci_Position length, int initStyle, WordList *keywordlists[], Accessor &styler) const; friend class Catalogue; diff --git a/lexlib/LexerNoExceptions.h b/lexlib/LexerNoExceptions.h index 2a846884e..ba24a8eb7 100644 --- a/lexlib/LexerNoExceptions.h +++ b/lexlib/LexerNoExceptions.h @@ -21,8 +21,8 @@ public: void SCI_METHOD Lex(Sci_PositionU startPos, Sci_Position lengthDoc, int initStyle, IDocument *pAccess); void SCI_METHOD Fold(Sci_PositionU startPos, Sci_Position lengthDoc, int initStyle, IDocument *); - virtual void Lexer(unsigned int startPos, int length, int initStyle, IDocument *pAccess, Accessor &styler) = 0; - virtual void Folder(unsigned int startPos, int length, int initStyle, IDocument *pAccess, Accessor &styler) = 0; + virtual void Lexer(Sci_PositionU startPos, Sci_Position length, int initStyle, IDocument *pAccess, Accessor &styler) = 0; + virtual void Folder(Sci_PositionU startPos, Sci_Position length, int initStyle, IDocument *pAccess, Accessor &styler) = 0; }; #ifdef SCI_NAMESPACE |