<?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 set tab size for user defined language?]]></title><description><![CDATA[<p dir="auto">I have a user defined language for BiBTeX.</p>
<p dir="auto">I want to set tab size equal 2 but where can it be set?</p>
<p dir="auto">Under Settings &gt; Preference &gt; Language the Tab Settings list does not list bibtex (or bib).</p>
<p dir="auto">Thanks for your help!<br />
mario</p>
]]></description><link>https://community.notepad-plus-plus.org/topic/20287/how-to-set-tab-size-for-user-defined-language</link><generator>RSS for Node</generator><lastBuildDate>Tue, 15 Sep 2026 14:49:33 GMT</lastBuildDate><atom:link href="https://community.notepad-plus-plus.org/topic/20287.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 09 Nov 2020 13:52:29 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to set tab size for user defined language? on Mon, 09 Nov 2020 14:23:36 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/mario-valle" aria-label="Profile: Mario-Valle">@<bdi>Mario-Valle</bdi></a> ,</p>
<p dir="auto">As far as I know, there isn’t a native way in Notepad++ to change the tab setting on a per-UDL basis.</p>
<p dir="auto">That would be nice, and in theory, you could put in a <a href="https://community.notepad-plus-plus.org/topic/15741/faq-desk-feature-request-or-bug-report">feature request</a>.  Unfortunately, the UDL system doesn’t often get bug fixes, let alone feature requests.</p>
<p dir="auto">However, there may be a workaround; the underlying Scintilla library has a <a href="https://www.scintilla.org/ScintillaDoc.html#SCI_SETTABWIDTH" rel="nofollow ugc"><code>SCI_SETTABWIDTH</code> message</a>, which you can access through a variety of means, including the PythonScript plugin (<code>editor.setTabWidth(2)</code> will change it to two spaces per tab).  With some logic, you could write a PythonScript that determines whether the active editor is editing a BiBTeX-UDL-based file, and if so, run that PythonScript setting.  If you have PythonScript, or are willing to install it, someone here should be able to give you pointers on how to implement that logic.</p>
<p dir="auto"><strong>&lt;edit&gt;</strong> You might also need to change <a href="https://www.scintilla.org/ScintillaDoc.html#SCI_SETTABINDENTS" rel="nofollow ugc"><code>SCI_SETTABINDENTS</code></a>, depending on your <strong>Settings &gt; Preferences &gt; Language &gt; Tab Settings &gt; [Default]</strong> settings <strong>&lt;/edit&gt;</strong></p>
]]></description><link>https://community.notepad-plus-plus.org/post/59560</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/59560</guid><dc:creator><![CDATA[PeterJones]]></dc:creator><pubDate>Mon, 09 Nov 2020 14:23:36 GMT</pubDate></item><item><title><![CDATA[Reply to How to set tab size for user defined language? on Mon, 09 Nov 2020 14:18:05 GMT]]></title><description><![CDATA[<p dir="auto">Afaik you can’t define it per UDL with npp builtin functionality.<br />
One workaround might be to set it as default and reconfigure it<br />
for builtin languages. Obviously works only if this UDL is the only one.<br />
Another option would be to use some “scripting” language if you want<br />
to go that way.</p>
]]></description><link>https://community.notepad-plus-plus.org/post/59559</link><guid isPermaLink="true">https://community.notepad-plus-plus.org/post/59559</guid><dc:creator><![CDATA[Ekopalypse]]></dc:creator><pubDate>Mon, 09 Nov 2020 14:18:05 GMT</pubDate></item></channel></rss>