<?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[Distinguishing single line and multi-line comments]]></title><description><![CDATA[<p dir="auto">I’m trying to set up UDL for Julia and I’m running into an issue with multi-line comments. The problem is that in Julia, single-line comments are delimited with a #, but multi-line comments are delimited with #= and =#, so whenever N++ sees a multi-line comment it just sees the # and assumes it’s a single-line comment and won’t highlight the remaining lines. Is there a way to get it to distinguish between the two types of comments? If I could use regex this would be easy, but apparently UDL does not support that at this time.</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/15982/distinguishing-single-line-and-multi-line-comments</link><generator>RSS for Node</generator><lastBuildDate>Wed, 10 Jun 2026 09:20:40 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/15982.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 30 Jun 2018 17:02:52 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Distinguishing single line and multi-line comments on Sun, 01 Jul 2018 16:33:07 GMT]]></title><description><![CDATA[<p dir="auto">Thank you very much! This is an adequate solution.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/33273</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/33273</guid><dc:creator><![CDATA[Dillon Ethier]]></dc:creator><pubDate>Sun, 01 Jul 2018 16:33:07 GMT</pubDate></item><item><title><![CDATA[Reply to Distinguishing single line and multi-line comments on Sat, 30 Jun 2018 23:01:02 GMT]]></title><description><![CDATA[<p dir="auto">Indeed, <a class="plugin-mentions-user plugin-mentions-a" href="/user/claudia-frank" aria-label="Profile: Claudia-Frank">@<bdi>Claudia-Frank</bdi></a> is right here - for this case it is better only to define line-comment by delimiters, and multi-line leave in the comments definition. This way only line comment will need a new command.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/33265</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/33265</guid><dc:creator><![CDATA[Mikhail V]]></dc:creator><pubDate>Sat, 30 Jun 2018 23:01:02 GMT</pubDate></item><item><title><![CDATA[Reply to Distinguishing single line and multi-line comments on Sat, 30 Jun 2018 20:54:20 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/dillon-ethier" aria-label="Profile: Dillon-Ethier">@<bdi>Dillon-Ethier</bdi></a></p>
<p dir="auto">in addition to what <a class="plugin-mentions-user plugin-mentions-a" href="/user/mikhail-v" aria-label="Profile: Mikhail-V">@<bdi>Mikhail-V</bdi></a> said you can use a combination of comments and delimiters like defining the multi-line comment as usual, with #= and =# and the line comment as suggested as an delimiter with open # and close ((EOL))</p>
<p dir="auto"><img src="https://camo.nodebb.org/1c49bcfb1ee7bb7934b32f2850785a3398559e7d?url=https%3A%2F%2Fi.imgur.com%2FSbTa1jP.png" alt="" class=" img-fluid img-markdown" /></p>
<p dir="auto">Cheers<br />
Claudia</p>
]]></description><link>https://community.notepad-plus-plus.org/post/33262</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/33262</guid><dc:creator><![CDATA[Claudia Frank]]></dc:creator><pubDate>Sat, 30 Jun 2018 20:54:20 GMT</pubDate></item><item><title><![CDATA[Reply to Distinguishing single line and multi-line comments on Sat, 30 Jun 2018 19:11:07 GMT]]></title><description><![CDATA[<p dir="auto">Unfortunately there are limitations in UDL. So with this one you are out of luck.<br />
I know one workaround for this.</p>
<p dir="auto">So to make colors work: in UDL you leave both “Comment line style” and “comment style” boxes empty.<br />
Then go to “operators and delimiters” tab and first define multiline comment delimiters,<br />
Open: #= Close: =#.<br />
Then (it must be defined after multiline delimiters) you define single line comment:<br />
Open: #  Close: ((EOL))</p>
<p dir="auto">Now the colors should work.</p>
<p dir="auto">After that you’ll need commands to comment/uncomment selections.<br />
This can be done via Pythonscript plugin.<br />
Actually it might be done just  with Regex replace but I prefer scripting solution.<br />
By scripting the idea is to define small scripts that work on selected text and insert # or #= where needed. If you know Python this should be easy to do.</p>
<p dir="auto">With Regex only this should work also but I am no expert in Regex.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/33260</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/33260</guid><dc:creator><![CDATA[Mikhail V]]></dc:creator><pubDate>Sat, 30 Jun 2018 19:11:07 GMT</pubDate></item></channel></rss>