<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[How to add Keyword class to cause highlighting]]></title><description><![CDATA[<p dir="auto">Hi I am trying to add a few new keywords to Verilog language. I have been studying <a href="https://notepad-plus-plus.org/community/topic/11561/custom-syntax-highlighting-js" rel="nofollow ugc">this thread</a> which has been quite helpful in creating a new Keyword Class “type1” for Verilog and giving it its own set of keywords.</p>
<pre><code>    &lt;Language name="verilog" ext="v sv vh svh" commentLine="//" commentStart="/*" commentEnd="*/"&gt;
        &lt;Keywords name="instre1"&gt;always and assign attribute begin buf bufif0 bufif1 case casex casez...
        &lt;Keywords name="instre2"&gt;SYNTHESIS $assertkill $assertoff $asserton $bits $bitstoreal...
        &lt;Keywords name="type1"&gt;test_word1 test_word2&lt;/Keywords&gt;
    &lt;/Language&gt;
</code></pre>
<p dir="auto">I add this also to the stylers.xml:</p>
<pre><code>    &lt;LexerType name="verilog" desc="Verilog" ext=""&gt;
          ...
        &lt;WordsStyle name="SPECIAL WORD" styleID="22" fgColor="A082BD" bgColor="293134" keywordClass="type1"&gt;&lt;/WordsStyle&gt;
          ...
    &lt;/LexerType&gt;
</code></pre>
<p dir="auto">The problem is that even though the style configuration can see the new keyword Class, it does not actually apply any syntax highlighting to any keywords in the new class…</p>
<p dir="auto">When I open the Style Configurator, I can see the “SPECIAL WORD” category with the correct color and Default Words come up, but then the words are not actually highlighted in the files with the appropriate extensions (*.v, *.sv, *.vh, etc.). Furthermore adding new user-defined keywords to the SPECIAL WORD category doesn’t cause them to be highlighted either. I have tried changing the styleID a few times…</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/13470/how-to-add-keyword-class-to-cause-highlighting</link><generator>RSS for Node</generator><lastBuildDate>Sat, 11 Apr 2026 02:26:04 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/13470.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 17 Mar 2017 16:38:40 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 18:12:15 GMT]]></title><description><![CDATA[<p dir="auto">I’ll give it a shot. If I am successful, I’ll for sure reply back</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22804</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22804</guid><dc:creator><![CDATA[A Stod]]></dc:creator><pubDate>Fri, 17 Mar 2017 18:12:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:58:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/7154">@A-Stod</a></p>
<p dir="auto">side note, the lexer itself (LexVerilog.cxx) is capable of using 6 keyword groups.</p>
<pre><code>class LexerVerilog : public ILexerWithSubStyles {
    CharacterSet setWord;
    WordList keywords;
    WordList keywords2;
    WordList keywords3;
    WordList keywords4;
    WordList keywords5;
    WordList ppDefinitions;
</code></pre>
<p dir="auto">and if you do it yourself it would be nice to let us know what you did,<br />
so that the next one could benefit :-)</p>
<p dir="auto">Thx and cheers<br />
Claudia</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22803</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22803</guid><dc:creator><![CDATA[Claudia Frank]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:58:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:47:59 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/7154">@A-Stod</a></p>
<p dir="auto">What needs to be done in regards of compiling npp and scintilla is described <a href="https://github.com/notepad-plus-plus/notepad-plus-plus" rel="nofollow ugc">here</a>.</p>
<p dir="auto">The file in question is ScintillaEditView.h.<br />
Whether this is the only place which needs to be modified or not I don’t know<br />
as I haven’t done it myself yet. But when you do have c++ knowledge you should be able to find out.</p>
<p dir="auto">Cheers<br />
Claudia</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22802</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22802</guid><dc:creator><![CDATA[Claudia Frank]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:47:59 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:40:06 GMT]]></title><description><![CDATA[<p dir="auto">Thank you for your help.</p>
<p dir="auto">Would you be so kind as to point me to exactly which files need to be edited to add another Keyword Class as well as a URL for a webpage containing the steps of how to recompile my version?</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22801</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22801</guid><dc:creator><![CDATA[A Stod]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:40:06 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:23:14 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/7154">@A-Stod</a></p>
<p dir="auto">depends, of course you can change the code and recompile your own version,<br />
but with the standard npp exe, no, not yet.<br />
What you can do is opening an enhancement request <a href="https://github.com/notepad-plus-plus/notepad-plus-plus/issues" rel="nofollow ugc">here</a>  and ask for changing it.</p>
<p dir="auto">Maybe <a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/34">@dail</a> 's new <a href="https://github.com/dail8859/ScintilluaPlusPlus" rel="nofollow ugc">scintillua plugin</a> might help you in the meantime but I haven’t had a chance to investigate what it can do or can’t.</p>
<p dir="auto">Cheers<br />
Claudia</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22800</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22800</guid><dc:creator><![CDATA[Claudia Frank]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:23:14 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:15:05 GMT]]></title><description><![CDATA[<p dir="auto">Oh I see. And it’s not possible to modify this right?</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22799</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22799</guid><dc:creator><![CDATA[A Stod]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:15:05 GMT</pubDate></item><item><title><![CDATA[Reply to How to add Keyword class to cause highlighting on Fri, 17 Mar 2017 17:10:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/7154">@A-Stod</a></p>
<p dir="auto">Verilog supports only two keyword lists, which are already used as instre1 and 2</p>
<pre><code>void setVerilogLexer(){
    setLexer(SCLEX_VERILOG, L_VERILOG, LIST_0 | LIST_1);
</code></pre>
<p dir="auto">Cheers<br />
Claudia</p>
]]></description><link>https://community.notepad-plus-plus.org/post/22798</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/22798</guid><dc:creator><![CDATA[Claudia Frank]]></dc:creator><pubDate>Fri, 17 Mar 2017 17:10:15 GMT</pubDate></item></channel></rss>