Scintillua PrivateLexerCall API Changes #47
orbitalquark
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've just committed some API changes that will likely affect users embedding Scintillua into their Scintilla-based applications. Scintilla 5.0.1 removed a couple of lexer APIs:
SCI_SETLEXERLANGUAGE
andSCI_LOADLEXERLIBRARY
. Scintillua's LPeg lexer uses theSCI_PRIVATELEXERCALL
interface for functionality like getting/setting the lexer, querying lexer and style names, etc. Such calls reuse existing Scintilla constants for convenience -- clients like SciTE that expose a script interface can make private lexer calls without needing any special#define
s or magic constants. A consequence of the Scintilla 5.0.1 API changes is that Scintillua's API also must change. Since API compatibility cannot be maintained, I took the opportunity to reshuffle 4 private lexer calls:SCI_SETLEXERLANGUAGE
->SCI_SETILEXER
(set lexer name)SCI_LOADLEXERLIBRARY
->SCI_CREATELOADER
(add path to Lua lexers)SCI_GETLEXERLANGUAGE
->SCI_GETLEXER
(get current lexer name)SCI_PROPERTYNAMES
->SCI_GETLEXERLANGUAGE
(get list of known lexers)If your application uses Scintillua and calls
SCI_PRIVATELEXERCALL
with any of these constants, you will have to make the necessary substitutions. As an example, Textadept had to make some changes. They're a bit more abstract than the usual C/C++ API calls, but you get the idea.Let me know if you have any questions or experience any difficulties. It is possible there will be more changes while the Scintilla 5 API remains unstable, but hopefully this is it for Scintillua.
Beta Was this translation helpful? Give feedback.
All reactions