[QScintilla] Lexer Issue

Phil Thompson phil at riverbankcomputing.com
Tue Sep 5 23:30:14 BST 2006


On Tuesday 05 September 2006 11:31 am, Micha Bieber wrote:
> > You need to write the new lexer for Scintilla (ignoring QScintilla), then
> > write the QScintilla high level class (which is really just a way of
> > avoiding Scintilla's property system), then the corresponding SIP
> > wrapper.
>
> I think, I can see it now. So, there is no way to transfer all of the
> customized lex/fold functionality from python classes to a qscintilla
> kernel at runtime. I have to compile a suiting LexerModule beforehand,
> the best here an ExternalLexerModule residing in a (re)loadable dynamic
> library, right?

You can build your lexer in with the main library if you want, it doesn't have 
to be separate.

Start with the existing lexer that is closest to the language you are adding 
support for.

> The reason for my question is kind of an interactively improved lexer,
> where the user can mark pieces of text from the qscintilla widget and
> gives them meaning on the fly (not keywords only, that should be
> possible - also block-opening characters/sentences, documentation
> markers etc.) and to apply the changes at once.
> To gain full control, the two function pointer arguments for the
> LexerModule ctor must be controllable at runtime as kind of python
> equivalents. I'm afraid, it stretches things too much, what a pity ... I
> I have to admit, it is somewhat special, though ..
>
> Anyway, thank you very much for guiding me,

Phil


More information about the QScintilla mailing list