<?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[Modify glyph selection with script]]></title><description><![CDATA[<p dir="auto">i can't seem to modify a font's glyph selection using a script...</p>
<pre><code class="language-python">CurrentFont().selection = ['A']
f.update()
</code></pre>
<p dir="auto">returns</p>
<pre><code class="language-console">Traceback (most recent call last):
  File "", line 1, in 
AttributeError: can't set attribute
</code></pre>
<p dir="auto">and</p>
<pre><code class="language-python">CurrentFont().selection.append('A')
</code></pre>
<p dir="auto">returns no error but makes no change to the selection, even after a <code>CurrentFont().update()</code></p>
<p dir="auto">Maybe there is a reason this doesn't work, or another way to accomplish this?</p>
<p dir="auto">thanks!</p>
]]></description><link>https://forum.robofont.com/topic/66/modify-glyph-selection-with-script</link><generator>RSS for Node</generator><lastBuildDate>Wed, 22 Apr 2026 10:35:24 GMT</lastBuildDate><atom:link href="https://forum.robofont.com/topic/66.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 06 Nov 2011 18:23:45 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Modify glyph selection with script on Sun, 31 Dec 2017 22:00:23 GMT]]></title><description><![CDATA[<p dir="auto">i can't seem to modify a font's glyph selection using a script...</p>
<pre><code class="language-python">CurrentFont().selection = ['A']
f.update()
</code></pre>
<p dir="auto">returns</p>
<pre><code class="language-console">Traceback (most recent call last):
  File "", line 1, in 
AttributeError: can't set attribute
</code></pre>
<p dir="auto">and</p>
<pre><code class="language-python">CurrentFont().selection.append('A')
</code></pre>
<p dir="auto">returns no error but makes no change to the selection, even after a <code>CurrentFont().update()</code></p>
<p dir="auto">Maybe there is a reason this doesn't work, or another way to accomplish this?</p>
<p dir="auto">thanks!</p>
]]></description><link>https://forum.robofont.com/post/66</link><guid isPermaLink="true">https://forum.robofont.com/post/66</guid><dc:creator><![CDATA[djr]]></dc:creator><pubDate>Sun, 31 Dec 2017 22:00:23 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph selection with script on Sun, 06 Nov 2011 19:31:38 GMT]]></title><description><![CDATA[<p dir="auto">The reason is not clear :)</p>
<p dir="auto">will be working in the next update</p>
]]></description><link>https://forum.robofont.com/post/514</link><guid isPermaLink="true">https://forum.robofont.com/post/514</guid><dc:creator><![CDATA[frederik]]></dc:creator><pubDate>Sun, 06 Nov 2011 19:31:38 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph selection with script on Sun, 06 Nov 2011 19:53:35 GMT]]></title><description><![CDATA[<p dir="auto">there is a work around</p>
<p dir="auto">f = CurrentFont()</p>
<p dir="auto">g = f["a"]<br />
g.selected = True</p>
<p dir="auto">(works well when you haven't selected a smart list item, so all glyphs should be active, this bug will be solved too :)</p>
]]></description><link>https://forum.robofont.com/post/515</link><guid isPermaLink="true">https://forum.robofont.com/post/515</guid><dc:creator><![CDATA[frederik]]></dc:creator><pubDate>Sun, 06 Nov 2011 19:53:35 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph selection with script on Mon, 07 Nov 2011 13:13:27 GMT]]></title><description><![CDATA[<p dir="auto">&gt; The reason is not clear :)</p>
<p dir="auto">:-)</p>
<p dir="auto">Thank you!</p>
]]></description><link>https://forum.robofont.com/post/516</link><guid isPermaLink="true">https://forum.robofont.com/post/516</guid><dc:creator><![CDATA[djr]]></dc:creator><pubDate>Mon, 07 Nov 2011 13:13:27 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph selection with script on Sun, 31 Dec 2017 22:01:33 GMT]]></title><description><![CDATA[<p dir="auto">in case it is helpful: it seems like the workaround you provided works with glyphs that contain outlines, but not with glyphs that only contain components (for example accents in my font)</p>
<pre><code class="language-python">f = CurrentFont()
f['aacute'].selected = True
f['a'].selected = True
</code></pre>
<p dir="auto">the code above, run when all glyphs are shown, will select <code>a</code> but not <code>aacute</code>.</p>
]]></description><link>https://forum.robofont.com/post/520</link><guid isPermaLink="true">https://forum.robofont.com/post/520</guid><dc:creator><![CDATA[djr]]></dc:creator><pubDate>Sun, 31 Dec 2017 22:01:33 GMT</pubDate></item></channel></rss>