<?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 remove the space when commenting lines?]]></title><description><![CDATA[<p dir="auto">Every time I press <strong>Ctrl+Q</strong> the text is commented in this way:<br />
<strong>; instructions</strong></p>
<p dir="auto">But I want it to be that way:<br />
<strong>;intructions</strong></p>
<p dir="auto">How can I do that? It is not useful to replace the text <strong>"; "</strong> by <strong>“;”</strong> as this way it is not portable to other languages.</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/19432/how-to-remove-the-space-when-commenting-lines</link><generator>RSS for Node</generator><lastBuildDate>Wed, 22 Jul 2026 23:53:59 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/19432.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 19 May 2020 23:25:17 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:40:27 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/terry-r" aria-label="Profile: Terry-R">@<bdi>Terry-R</bdi></a> These are valid options and I did think of them, but I was hoping there was a way to configure notepad++ without doing anything, I’ll try my luck on Github and thanks for everything.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54103</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54103</guid><dc:creator><![CDATA[Willy]]></dc:creator><pubDate>Wed, 20 May 2020 02:40:27 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:30:09 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/willy" aria-label="Profile: Willy">@<bdi>Willy</bdi></a> said in <a href="/post/54101">How to remove the space when commenting lines?</a>:</p>
<blockquote>
<p dir="auto">don’t mix styles</p>
</blockquote>
<p dir="auto">That’s a fair comment. Why not use a regex (regular expression) that you run as you do the final save of the file. It can remove that space at the start of the comment lines fairly easily. Otherwise go through ALL the old code and change them to suit the current format. That’s probably going to be the quickeest way to sort it out (short to medium term). Then ask for a feature request. It’s a valid request, but I don’t think it’s a valid <strong>bug</strong>.</p>
<p dir="auto">Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54102</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54102</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Wed, 20 May 2020 02:30:09 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:26:52 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/terry-r" aria-label="Profile: Terry-R">@<bdi>Terry-R</bdi></a> No, I don’t consider it a error/bug, I just need that functionality, and yes, you are right that a comment is a comment and that space shouldn’t matter, it even seems a bit immature the request but the code already has that style in several lines and I can’t ruin the code with a different style, it wouldn’t be constant.</p>
<p dir="auto">Use whatever style you want but be constant and don’t mix styles, I was taught that way.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54101</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54101</guid><dc:creator><![CDATA[Willy]]></dc:creator><pubDate>Wed, 20 May 2020 02:26:52 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:26:20 GMT]]></title><description><![CDATA[<p dir="auto">Actually, why not consider it a “feature request”.</p>
<p dir="auto">See:<br />
<a href="https://community.notepad-plus-plus.org/topic/15741/faq-desk-feature-request-or-bug-report">https://community.notepad-plus-plus.org/topic/15741/faq-desk-feature-request-or-bug-report</a></p>
<p dir="auto">Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54100</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54100</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Wed, 20 May 2020 02:26:20 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:23:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/willy" aria-label="Profile: Willy">@<bdi>Willy</bdi></a> said in <a href="/post/54097">How to remove the space when commenting lines?</a>:</p>
<blockquote>
<p dir="auto">my problem is that notepad++ always adds a space when I comment</p>
</blockquote>
<p dir="auto">And I agreed (after testing) with that statement. I’m also saying I don’t think it’s a bug. Consider what you are doing. You are entering a comment. Regardless of which language you code in comments are ALWAYS regarded as “free speech” (to my knowledge). I don’t see the issue with having a space before your “comments”. If indeed there is an issue then it can’t be a <code>real</code> comment, it would seem you are using this “code type” for other purposes, thus needing an exact format.</p>
<p dir="auto">You can look through various posts here (use search) for github to find the links, however as I say, consider what you are asking for. I doubt VERY much it would be considered a bug at all. I don’t see it anywhere in settings/preferences so it’s not overridable (to my knowledge).</p>
<p dir="auto">Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54099</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54099</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Wed, 20 May 2020 02:23:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 02:16:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/terry-r" aria-label="Profile: Terry-R">@<bdi>Terry-R</bdi></a> <strong>“my problem is that notepad++ always adds a space when I comment”</strong></p>
<p dir="auto">So no matter what language I’m working on, I’ll use Ruby, C, C++, Assembler whatever and I don’t want the space when commenting, that’s it.</p>
<p dir="auto">I didn’t say Notepad++ was changing the “#” to “;” or anything like that, I just picked a language at random and it was Ruby, all languages have the comment character without the space in <strong>langs.xml</strong> so where should I go? Github?</p>
<p dir="auto">If I go to Github what I’d be asking is that they implement the function and obviously that takes time, I wanted something fast, maybe something I was ignoring.</p>
<p dir="auto">You insist that Github is my only option? If so, I’ll go to Github.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54097</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54097</guid><dc:creator><![CDATA[Willy]]></dc:creator><pubDate>Wed, 20 May 2020 02:16:26 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 01:49:32 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/willy" aria-label="Profile: Willy">@<bdi>Willy</bdi></a> said in <a href="/post/54092">How to remove the space when commenting lines?</a>:</p>
<blockquote>
<p dir="auto">not like I can do anything to take the space away, it’s something from Notepad++</p>
</blockquote>
<p dir="auto">You may be right here. I’ve completed some testing selecting various languages and each time I press the Ctrl-Q shortcut it inserts the comment character(s) for the selected language, and then appends a <code>space</code>. It does prove you aren’t selecting Ruby as the language or using the ruby file extensions though as you get the <code>;</code>, not the <code>#</code> character.</p>
<p dir="auto">So regardless of which language is selected it would appear the default setting is to <code>append</code> a space behind the <code>commentLine</code> character specified (in langs.xml file) according to language/file extensions. This would need to be raised as a bug (? not sure <code>bug</code> is the right word, the developer has probably just decided that’s the correct approach) on GitHub I think. I believe that’s where all these things are worked on, not on this forum.</p>
<p dir="auto">Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54094</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54094</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Wed, 20 May 2020 01:49:32 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 01:18:42 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/willy" aria-label="Profile: Willy">@<bdi>Willy</bdi></a> said in <a href="/post/54092">How to remove the space when commenting lines?</a>:</p>
<blockquote>
<p dir="auto">As you see there are no spaces in the “#” character</p>
</blockquote>
<p dir="auto">Actually from my limited knowledge of this setting I’d say NPP isn’t interpreting your code as Ruby, otherwise it would have used the <code>#</code> as you show from the langs.xml file, not the <code>; </code>. I also note that <code>#</code> is the comment line for Ruby in the real world. What file extensions are you using? That may be how NPP is acknowledging the code, so look in the langs.xml file again for the extensions you are using and check the relevant comment info.</p>
<p dir="auto">Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54093</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54093</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Wed, 20 May 2020 01:18:42 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Wed, 20 May 2020 00:55:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/terry-r" aria-label="Profile: Terry-R">@<bdi>Terry-R</bdi></a> Hi, that’s what you’re saying is to change the character for another one, that’s not my <strong>problem</strong>, my problem is that notepad++ always adds a space when I comment and that’s what I want to avoid, I read the <strong>langs.xml</strong> file and look at this line for the Ruby language:</p>
<pre><code>&lt;Language name="ruby" ext="rb rbw" commentLine="#"&gt;
</code></pre>
<p dir="auto">As you see there are no spaces in the <strong>“#”</strong> character so it’s not like I can do anything to take the space away, it’s something from Notepad++</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54092</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54092</guid><dc:creator><![CDATA[Willy]]></dc:creator><pubDate>Wed, 20 May 2020 00:55:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to remove the space when commenting lines? on Tue, 19 May 2020 23:41:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/willy" aria-label="Profile: Willy">@<bdi>Willy</bdi></a> said in <a href="/post/54090">How to remove the space when commenting lines?</a>:</p>
<blockquote>
<p dir="auto">the text is commented in this way:</p>
</blockquote>
<p dir="auto">If you were to read the Notepad++ documentation, specifically the config files it may help. See:<br />
<a href="https://npp-user-manual.org/docs/config-files/" rel="nofollow ugc">https://npp-user-manual.org/docs/config-files/</a></p>
<p dir="auto">Look for the langs.xml file detail. I presume you have a specific language you are using, perhaps ASM files. It would appear that you can define the comment start characters by editing this file.<br />
I haven’t tried this.</p>
<p dir="auto">Good luck<br />
Terry</p>
]]></description><link>https://community.notepad-plus-plus.org/post/54091</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/54091</guid><dc:creator><![CDATA[Terry R]]></dc:creator><pubDate>Tue, 19 May 2020 23:41:04 GMT</pubDate></item></channel></rss>