<?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 setup UDL keyword style overwrites?]]></title><description><![CDATA[<p dir="auto">Hello<br />
I am creating a UDL for a niche script, and trying to highlight <strong>‘Parent’</strong> as a keyword in such a way that it will only be highlighted if followed immediately by a <strong>‘(’</strong> , or following immediately after a <strong>'= ’</strong> :</p>
<pre><code>DATA
{
	type = CelestialBody
	targetBody1 = HomeWorld().Parent()
}

DATA
{
	type = Parent
}
</code></pre>
<p dir="auto">but not when it’s on its own:</p>
<pre><code>DATA
{
	synopsis = Place a relay on a Parent celestial body.
}
</code></pre>
<p dir="auto">It doesn’t seem as though I can override it using another keywords group or with the Folding in Code/Comment styles.<br />
Is there any way to do this? With delimiters perhaps?</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/17019/how-to-setup-udl-keyword-style-overwrites</link><generator>RSS for Node</generator><lastBuildDate>Sun, 12 Apr 2026 02:33:02 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/17019.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 29 Jan 2019 16:05:21 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Wed, 30 Jan 2019 10:34:17 GMT]]></title><description><![CDATA[<p dir="auto">I’ve realised that some of the <strong>{ }</strong> brackets aren’t coloured properly anymore, but only after instances of <strong>DATA</strong> or <strong>PARAMETER</strong>, and for some reason <strong>//</strong> comments after instances of <strong>PARAMETER</strong> don’t highlight either. Well, this is perplexing.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/39121</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39121</guid><dc:creator><![CDATA[Hanna Shipway]]></dc:creator><pubDate>Wed, 30 Jan 2019 10:34:17 GMT</pubDate></item><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Wed, 30 Jan 2019 09:50:37 GMT]]></title><description><![CDATA[<p dir="auto">Thank you for the information :)</p>
<p dir="auto">I added the rest of the keywords to the .xml and uploaded it (same link as before). This fixes <strong>HomeWorld()</strong> because it wasn’t part of the list before. They’re now separated into two delimiters <em>(1&amp;2, former 2 has now moved to 3)</em> as one of the keyword groups I wanted to apply this to is a different colour. I also checked <em>D2</em>’s nesting in the comment style options to support this separation.</p>
<p dir="auto">It did break highlighting for numbers inside brackets, but checking <em>D1</em> and <em>D2</em> nesting inside of <em>D3</em>’s options seems to fix it.</p>
<p dir="auto">The <strong>‘=’</strong> situation is a little complicated however. I originally put it in the comment style as it would allow it to ignore any spaces after it, hence why when moved to <em>Operators 1</em> it won’t highlight keywords after a <strong>‘=’</strong> anymore (such as the case you found with <em>LAN</em>). I guess this is personal preference, but I kept it in comments, even if the equal sign stays black.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/39120</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39120</guid><dc:creator><![CDATA[Hanna Shipway]]></dc:creator><pubDate>Wed, 30 Jan 2019 09:50:37 GMT</pubDate></item><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Wed, 30 Jan 2019 09:22:29 GMT]]></title><description><![CDATA[<p dir="auto">@Adam-Shipway</p>
<p dir="auto">nice work, thanks for exporting and sharing. 👍</p>
<blockquote>
<p dir="auto">Any help with getting ‘=’ to highlight differently, as well as any ways to clean up my messy UDL setup, would be greatly appreciated.</p>
</blockquote>
<p dir="auto">i’ve made one single modification that delivers following result with caveats:</p>
<p dir="auto"><img src="https://camo.nodebb.org/51b1140c6109c66b3a8975529e668f8a8c718ca9?url=https%3A%2F%2Fi.imgur.com%2Ffavep2l.png" alt="Imgur" class=" img-fluid img-markdown" /></p>
<p dir="auto">changes:<br />
i’ve removed the <code>=</code> to <code>((EOL))</code> of the nesting comment line and added <code>=</code> to operators 1</p>
<p dir="auto">pro: <code>HomeWorld()</code> is highlighted correctly as keyword (before, with the nesting <code>=</code>comment style, it was black)</p>
<p dir="auto">con: at <code>test = LAN</code> LAN does not get highlighted anymore due to the space.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/39118</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39118</guid><dc:creator><![CDATA[Meta Chuh]]></dc:creator><pubDate>Wed, 30 Jan 2019 09:22:29 GMT</pubDate></item><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Wed, 30 Jan 2019 04:23:23 GMT]]></title><description><![CDATA[<p dir="auto"><strong>Updated link</strong> for results in case the previous one fails or is unclear: <a href="https://i.imgur.com/DMPUBmH.png" rel="nofollow ugc">https://i.imgur.com/DMPUBmH.png</a></p>
]]></description><link>https://community.notepad-plus-plus.org/post/39115</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39115</guid><dc:creator><![CDATA[Hanna Shipway]]></dc:creator><pubDate>Wed, 30 Jan 2019 04:23:23 GMT</pubDate></item><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Wed, 30 Jan 2019 04:01:57 GMT]]></title><description><![CDATA[<p dir="auto">Thanks for the effort to help. It’s disappointing that languages requiring spaces sometimes don’t work well with the UDL system.</p>
<p dir="auto">I’m wondering if, since comments ignore spaces in their styling, they could be incorporated. I’m also wondering if nesting can be used to have anything inside the brackets be styled differently.</p>
<p dir="auto">---- I did some messing around and I was able to get this result, where I believe the only problem is that the <strong>‘=’</strong> sign isn’t highlighted properly:<br />
<a href="https://i.imgur.com/H5nGnZ2.jpg" rel="nofollow ugc">https://i.imgur.com/H5nGnZ2.jpg</a> (Edit: look at that quality from the new Win10 Snip tool! Eugh!)</p>
<p dir="auto">Using these settings (which I’ve listed, as screenshots would take an excessive amount of room):</p>
<p dir="auto">Keyword Group 1 (Blue, Prefix Off): <strong>Parent Random LAN</strong></p>
<p dir="auto">Comment style (Black, Not Line):<br />
Open: <strong>=</strong><br />
Close: <strong>((EOL))</strong><br />
Nesting: <strong>Delimiter 1, All KW Groups, Comment Line, All Operators, Numbers</strong></p>
<p dir="auto">Delimiter 1 (Blue):<br />
Open: <strong>Random( Parent( LAN(</strong><br />
Close: <strong>) ((EOL)) ((EOL)) ((EOL))</strong><br />
Nesting: <strong>All KW Groups, Comment &amp; Comment Line, All Operators, Numbers</strong></p>
<p dir="auto">Delimiter 2 (Black):<br />
Open: <strong>Random Parent LAN</strong><br />
Close: <strong>((EOL)) ((EOL)) ((EOL))</strong><br />
Nesting: <strong>Numbers</strong></p>
<p dir="auto">The entire UDL .xml file as it is currently (I have only ported 3 keywords to use the setup as of now): <a href="https://www.dropbox.com/s/od8sku0wkpceh79/contractcfg.xml?dl=0" rel="nofollow ugc">https://www.dropbox.com/s/od8sku0wkpceh79/contractcfg.xml?dl=0</a><br />
A file for use with the language (tests at bottom): <a href="https://www.dropbox.com/s/mi1caxm5hsnvg9q/wd_lKard.cfg?dl=0" rel="nofollow ugc">https://www.dropbox.com/s/mi1caxm5hsnvg9q/wd_lKard.cfg?dl=0</a></p>
<p dir="auto">Any help with getting ‘=’ to highlight differently, as well as any ways to clean up my messy UDL setup, would be greatly appreciated.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/39114</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39114</guid><dc:creator><![CDATA[Hanna Shipway]]></dc:creator><pubDate>Wed, 30 Jan 2019 04:01:57 GMT</pubDate></item><item><title><![CDATA[Reply to How to setup UDL keyword style overwrites? on Tue, 29 Jan 2019 21:37:42 GMT]]></title><description><![CDATA[<p dir="auto">welcome to the notepad++ community, @Adam-Shipway</p>
<p dir="auto">i won’t say impossible, but this one is gonna be tricky 😉</p>
<p dir="auto">i’ve played around a bit using delimiters instead of keywords, as they were suggested by <a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/13724">@Eko-palypse</a> a couple of weeks ago, but in your case, i’m a bit stuck on a few things that might be ugly (as seen at the screenshot below):</p>
<ul>
<li>
<p dir="auto">i get <code>parent</code>to correctly highlight if succeeded by a ( or preceeded by a =, but only if there’s no space in between prefix/suffix and the word <code>parent</code></p>
</li>
<li>
<p dir="auto">one thing that i couldn’t get fixed, is that the highlighting of <code>parent(void)</code> also highlights everything within the () brackets.</p>
</li>
</ul>
<p dir="auto">anyways, here’s the screenshot in hope that you can use any of those settings for some of your needs.</p>
<p dir="auto"><img src="https://camo.nodebb.org/8833ce56c6ec74703c11e9d9169fff405ac11608?url=https%3A%2F%2Fi.imgur.com%2F3kDbPdT.png" alt="Imgur" class=" img-fluid img-markdown" /></p>
<p dir="auto">please keep us informed of any success you had, as well as any further problems you might encounter.</p>
<p dir="auto">ps: <a class="plugin-mentions-user plugin-mentions-a" href="https://community.notepad-plus-plus.org/uid/3841">@PeterJones</a> “exhumed” this old but very good udl documentation for us, just in case you don’t have it yet:<br />
<a href="https://ivan-radic.github.io/udl-documentation/comments/" rel="nofollow ugc">https://ivan-radic.github.io/udl-documentation/comments/</a></p>
]]></description><link>https://community.notepad-plus-plus.org/post/39107</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/39107</guid><dc:creator><![CDATA[Meta Chuh]]></dc:creator><pubDate>Tue, 29 Jan 2019 21:37:42 GMT</pubDate></item></channel></rss>