[Qt-interest] Generic Highlighter with multiple definitions for onefile?

NoRulez norulez at me.com
Sat Jul 9 16:59:09 CEST 2011


Hi,

I use already the generic highlighter from the Qt Creator. My problem is only to highlight multiple sources per file.

Could you give me a little example to show how it works?

Best Regards

Am 09.07.2011 um 11:40 schrieb Diego Iastrubni <diegoiast at gmail.com>:

> The generic highlighter available in QtCreator can handle this task. It's based on Kate. You can de-couple it from the IDE and use it in your application. It's released under LGPL.
> 
> On Sat, Jul 9, 2011 at 7:27 AM, Scott Aron Bloom <Scott.Bloom at onshorecs.com> wrote:
> Use multiple  QSyntaxHighlighter, one setup for each set of rules you
> need..
> 
> When a file is loaded select the correct one, and call setDocument on
> the correct highlighter for the editor in use..
> 
> Scott
> 
> -----Original Message-----
> From: qt-interest-bounces+scott.bloom=onshorecs.com at qt.nokia.com
> [mailto:qt-interest-bounces+scott.bloom=onshorecs.com at qt.nokia.com] On
> Behalf Of NoRulez
> Sent: Friday, July 08, 2011 10:02 AM
> To: Qt Interest MailingList
> Subject: [Qt-interest] Generic Highlighter with multiple definitions for
> onefile?
> 
> Hi,
> 
> if I use the generic highlighter per file (e.g. html) it works
> perfectly.
> 
> The problem I have is when a file has multiple sources such as a HTML or
> a PHP file. These files could have PHP/HTML source and JavaScript and/or
> CSS for example.
> 
> How can I combine such highlighters to highlight the PHP/HTML source and
> also the JS and CSS?
> 
> Thanks in advance
> 
> Best regards
> NoRulez
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110709/e125d953/attachment.html 


More information about the Qt-interest-old mailing list