<?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[Location navigate plugin + Python editor.markerAdd() colors]]></title><description><![CDATA[<p dir="auto">When i set the colors of a python marker and add a mark, the location navigate plugin will override those colors if i have modified a line. Is there anyway around this?</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/21282/location-navigate-plugin-python-editor-markeradd-colors</link><generator>RSS for Node</generator><lastBuildDate>Sun, 09 Aug 2026 19:13:13 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/21282.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 06 Jun 2021 21:09:43 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Tue, 08 Jun 2021 01:00:05 GMT]]></title><description><![CDATA[<p dir="auto">Thanks for the very detailed responses.<br />
Properties look like they might do the trick for me.<br />
I will definitely read the Scintilla docs as i’m sure i haven’t implemented them properly.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66834</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66834</guid><dc:creator><![CDATA[Anthony Blinco]]></dc:creator><pubDate>Tue, 08 Jun 2021 01:00:05 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Mon, 07 Jun 2021 13:33:41 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/anthony-blinco" aria-label="Profile: Anthony-Blinco">@<bdi>Anthony-Blinco</bdi></a> said in <a href="/post/66773">Location navigate plugin + Python editor.markerAdd() colors</a>:</p>
<blockquote>
<p dir="auto">I am using 16, i have tried 8 as well and it still apears to override my colors.</p>
</blockquote>
<p dir="auto">If you haven’t already, it’s worth giving <a href="https://www.scintilla.org/ScintillaDoc.html#Markers" rel="nofollow ugc">Markers section of Scintilla docs</a> a read.  You define a marker and map it to a type - defined colors for it and then it is applied cumulatively to a line.  Marker numbers are just powers of 2 (0-31) to fill in a bitmap to tell which marker values are enabled for each line.</p>
<p dir="auto">For example, using Location Navigate and a Notepad++ bookmark all on the same line, the marker value is:</p>
<pre><code>DEC: 16778240
BIN: 0000 0001 0000 0000 0000 0100 0000 0000
</code></pre>
<p dir="auto">After saving, the value is:</p>
<pre><code>DEC: 16779264
BIN: 0000 0001 0000 0000 0000 1000 0000 0000
</code></pre>
<p dir="auto"><img src="/assets/uploads/files/1623072715691-154023b1-095f-4f1b-9ba9-fff72f01ca61-image.png" alt="154023b1-095f-4f1b-9ba9-fff72f01ca61-image.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">Notice, the most significant <code>1</code> in the marker value doesn’t change - that’s the Notepad++ bookmark marker value 24.  The least significant <code>1</code> in both numbers does change - that’s LocNav using 10 for a change marker and 11 for a saved marker.  In both instances, the actual “marker” number for the line is the “total” of all markers on that line.</p>
<p dir="auto">Hope this helps.</p>
<p dir="auto">Cheers.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66799</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66799</guid><dc:creator><![CDATA[Michael Vincent]]></dc:creator><pubDate>Mon, 07 Jun 2021 13:33:41 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Mon, 07 Jun 2021 12:42:38 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ekopalypse" aria-label="Profile: Ekopalypse">@<bdi>Ekopalypse</bdi></a> go this far, so I’ll add this:</p>
<p dir="auto">If you <code>.setProperty()</code>, that property value string gets attached to the active file document.<br />
If you switch documents and do a <code>.getProperty()</code> for the same property argument, you’ll get an empty string returned.<br />
If you switch back to the original doc and do a <code>.getProperty()</code> on the property argument, you’ll get your original value returned.</p>
<p dir="auto">Maybe obvious, but perhaps worth explicitly stating.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66796</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66796</guid><dc:creator><![CDATA[Alan Kilborn]]></dc:creator><pubDate>Mon, 07 Jun 2021 12:42:38 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Mon, 07 Jun 2021 10:05:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/anthony-blinco" aria-label="Profile: Anthony-Blinco">@<bdi>Anthony-Blinco</bdi></a></p>
<p dir="auto">There are several ways to accomplish this, my preferred way when I need flags is to use the setProperty and getProperty methods</p>
<pre><code>&gt;&gt;&gt; help(editor.setProperty)
Help on method setProperty:

setProperty(...) method of Npp.Editor instance
    setProperty( (Editor)arg1, (object)key, (object)value) -&gt; None :
        Set up a value that may be used by a lexer for some optional feature.


&gt;&gt;&gt; help(editor.getProperty)
Help on method getProperty:

getProperty(...) method of Npp.Editor instance
    getProperty( (Editor)arg1, (object)key) -&gt; str :
        Retrieve a "property" value previously set with SetProperty.
        Result is NUL-terminated.
</code></pre>
<p dir="auto">so with something like</p>
<pre><code class="language-py">editor.setProperty('initialized', '1')
editor.getProperty('initialized')
</code></pre>
]]></description><link>https://community.notepad-plus-plus.org/post/66788</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66788</guid><dc:creator><![CDATA[Ekopalypse]]></dc:creator><pubDate>Mon, 07 Jun 2021 10:05:04 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Sun, 06 Jun 2021 23:27:45 GMT]]></title><description><![CDATA[<p dir="auto">On an issue related to this.<br />
I am leaving markers in the text file to indicate which lines have been marked.<br />
I use a startup script callback BUFFERACTIVATED to pre-process the file and set the markers , if any.<br />
<strong>Is there a way i can set some flag on a per buffer basis to say that i have already processed this file?</strong></p>
]]></description><link>https://community.notepad-plus-plus.org/post/66774</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66774</guid><dc:creator><![CDATA[Anthony Blinco]]></dc:creator><pubDate>Sun, 06 Jun 2021 23:27:45 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Sun, 06 Jun 2021 23:01:57 GMT]]></title><description><![CDATA[<p dir="auto">I am using 16, i have tried 8 as well and it still apears to override my colors.<br />
In the end i set Location navigate to use a mark in the margin rather than highlighting the line.<br />
I would much prefer the highlight though.<br />
Thanks for the info, very handy as usual</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66773</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66773</guid><dc:creator><![CDATA[Anthony Blinco]]></dc:creator><pubDate>Sun, 06 Jun 2021 23:01:57 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Sun, 06 Jun 2021 22:40:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/peterjones" aria-label="Profile: PeterJones">@<bdi>PeterJones</bdi></a> said in <a href="/post/66770">Location navigate plugin + Python editor.markerAdd() colors</a>:</p>
<blockquote>
<p dir="auto">doubt that Location Navigate uses all of 0…20</p>
</blockquote>
<p dir="auto">IIRC, Location Navigate uses 10 and 11 for saved and changed.</p>
<p dir="auto">Cheers.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66772</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66772</guid><dc:creator><![CDATA[Michael Vincent]]></dc:creator><pubDate>Sun, 06 Jun 2021 22:40:15 GMT</pubDate></item><item><title><![CDATA[Reply to Location navigate plugin + Python editor.markerAdd() colors on Sun, 06 Jun 2021 21:33:03 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/anthony-blinco" aria-label="Profile: Anthony-Blinco">@<bdi>Anthony-Blinco</bdi></a> ,</p>
<p dir="auto">Perhaps try to choose a marker ID that Location Navigate doesn’t use.  There are only 32 <a href="https://www.scintilla.org/ScintillaDoc.html#SCI_MARKERADD" rel="nofollow ugc">marker numbers</a> (0…31) and 25…31 are used by Scintilla, and 21-24 appear to also be defined by Notepad++.  I doubt that Location Navigate uses all of 0…20, so you could keep trying until you found one that LN doesn’t use (or check LN’s source code).</p>
<p dir="auto">I checked for which ones were already defined on my setup using the PythonScript console:</p>
<pre><code>&gt;&gt;&gt; for mn in range(0,32):
...     console.write("symbol#{} =&gt; {:02x}\n".format(mn, editor.markerSymbolDefined(mn)))
... 
</code></pre>
<p dir="auto">You could probably do something similar on yours… maybe make sure that LN has marked changed lines before running that, in case it doesn’t add in its markers until it finds changed lines for the first time.</p>
<p dir="auto">Good luck.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/66770</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/66770</guid><dc:creator><![CDATA[PeterJones]]></dc:creator><pubDate>Sun, 06 Jun 2021 21:33:03 GMT</pubDate></item></channel></rss>