We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

multiline lexem not working

Thread ID:





117412 Oct 16,2014 07:13 AM Oct 24,2014 10:12 AM Windows Forms 6
Tags: EditControl
Olivier Duhart
Asked On October 16, 2014 07:13 AM


I am developing an editor for our own language. I managed to match all simple lexems like keywords or simple operators.
But I cant find the way to match multilines lexems.
I have 2 kinds of multiline patterns :

 - comments that match the classic /* .... */ pattern or single line with 2 leading dash.
 currently I tried, where Comment format is green bold 10pt Verdana :

<lexem BeginBlock="/*"              
             ContinueBlock = ".+" IsContinueRegex = "true"
             Type="Comment" />

But it does not even display the /* and */ with the correct format.
the same happens wih on line comment not matching

       <lexem BeginBlock="--"  Type="Commentaire"/>

And finally for multiline strings (with single quote delimitor) not working with (except for first line)

<lexem BeginBlock="'" EndBlock="'" Type="String" IsComplex="true" 
   ContinueBlock="(.|\n)+" IsContinueRegex="true" OnlyLocalSublexems="true"
       IndentationGuideline="true" IsMultiline="true"/>  

You will find my complete configuration XML in attachment

thanks for your help,


Attachment: config_b6b6eb65.zip

Olivier Duhart
Replied On October 16, 2014 07:54 AM

I forgot to mention my syncfusion version is


Saravanan T [Syncfusion]
Replied On October 20, 2014 11:07 AM

Hi Olivier,


Thank you for using Syncfusion products,


We would like to let you know that your requirement can be achieved by using below code snippet.


Code Snippet [C#]:


<lexem BeginBlock="/*" EndBlock="*/" Type="Comment" OnlyLocalSublexems="true" IsComplex="true"

    IsCollapsable="true" CollapseName="/*...*/" AllowTriggers="false">


    <lexem BeginBlock="/*" Type="Comment" />

    <lexem BeginBlock="\n" IsBeginRegex="true" />




Please let us know if you need any further assistance,



Saravanan T

Olivier Duhart
Replied On October 21, 2014 05:42 AM


I tried your solution but it did not work :(
I just copy-paste your snippet, replacing my comment configuration. So my config.xml is the same that I joined except the comment part.

Could you check this and maybe send me a more complete sample (XML + C# ) ?



Olivier Duhart
Replied On October 22, 2014 07:30 AM

I managed to colored a multiline string with

but  I never succeeded adpting this pattern foor comment coloring.

In fact even simple lexems like those below do not work :

     <lexem Type="Comment" BeginBlock="--" IsBeginRegex="false" />
      <lexem Type="Comment" BeginBlock="/*" IsBeginRegex="false" />

Is there something special with those beginBlock that prevent them to work ? I tried playing  with IsBeginRegex = true/ false but ntohing changed


Olivier Duhart
Replied On October 23, 2014 05:02 AM


I was missing the <splits></splits> part for activating comment highlighting

thanks for your help


Saravanan T [Syncfusion]
Replied On October 24, 2014 10:12 AM

Hi Oliver,


Thank you for your update,


We are glad to hear that the reported problem has been resolved.


Please let us know if you need any further assistance,



Saravanan T


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.