How to write the <ExplicitPatterns> TAG?

SyntaxEditor for Windows Forms Forum

Posted 15 years ago by Nassim Farhat
Version: 4.0.0281
Avatar
Hello ActiPro team,

I am trying to define my own language using Dynamic XML definition, which for beginners, I was told by the ActiPro team, was the easiest way to do so.

So I browsed through the documentation and I could not find explanation concerning the terms used inside the <ExplicitPatterns> tag (all the: &lt, &amp etc... symbols).

Can you please tell me where I can find proper documentation to help me figure out how the <ExplicitPatterns> tag works, how to define it, what all the details inside the example below mean (ex: &amp;= |= ^=) and why do you structure it that way?

1 more question: I did not find the ">,<,>=,<= etc.." operator definition in the C# example below... was that forgotten or am I not seeing something I should?

C# ex:


<ExplicitPatternGroup TokenKey="OperatorToken" Style="OperatorStyle">
<ExplicitPatterns>
=== !==
== !=
= !
++ --
+= -= *= /= %=
-&gt;
+ - * / %
&amp;&amp; ||
&amp;= |= ^=
&amp; | ~ ^
&lt;&lt;= &gt;&gt;=
&lt;&lt; &gt;&gt;
&lt;= &lt; &gt;= &gt;
?? ?
</ExplicitPatterns>
</ExplicitPatternGroup>

Thank you
Nassim

Comments (1)

Posted 15 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Nassim,

All those tags are documented in the Dynamic Language Guide part of the documentation.

Things like &amp; are standard XML escape characters.
&amp; = &
&gt; = >
&lt; = <

So when defining explicit patterns in the XML definition that use those characters, you must escape them or wrap the inner content with a CDATA section.


Actipro Software Support

The latest build of this product (v24.1.0) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.