[QScintilla] create external lexer

Phil Thompson phil at riverbankcomputing.com
Thu Feb 28 08:53:13 GMT 2008


On Thursday 28 February 2008, Joan Pablo Jimenez Milian wrote:
> Hi, I'm new about QScintilla. I'm working in a simple IDE (to Linux) to
> learn more about Qt and QScintilla and for personal and my friends use.
>
> I know how to write a new Lexer but I want to create an External Lexer and
> load it as a Dynamic Library.
>
> I need some help about this, these are my problems :
>
> I have make the .so with the functions I need :
>
> void EXT_LEXER_DECL Lex(unsigned int lexer, unsigned int startPos, int
> length, int initStyle, char *words[], WindowID window, char *props); int
> EXT_LEXER_DECL GetLexerCount();
> void EXT_LEXER_DECL GetLexerName(unsigned int Index, char *name, int
> buflength); void EXT_LEXER_DECL Fold(unsigned int lexer, unsigned int
> startPos, int length, int initStyle, char *words[], WindowID window, char
> *props);
>
> 1-) But I don't know how to make a PropSet with props (I don't know what
> are props). I just know that I need PropSet and WindowID to make a
> WindowAccesor and use it as a Accesor style (or I'm wrong?).
>
> 2-) How can I load MyLexer.so from my QtApp (what code I should write).
>
> Please, any help. I will apreciate very much if somebody can explain me if
> posible with some sample code.

You are best asking on the Scintilla mailing list as these questions aren't 
specific to QScintilla.

However, I'm not sure that Scintilla can currently be used with external 
lexers. Also QScintilla does not include WindowAccessor.

Phil


More information about the QScintilla mailing list