<?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[SetDefault &amp; UpdateCurrentGlyphView]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">I think I found a bug. When setting a default for the GlyphView and UpdateCurrentGlyphView, it won't be visible until I reopen the GlyphView.<br />
For now all I want is to set the grid. Maybe it can be done more simple? Here is my code.</p>
<pre><code class="language-python">from lib.tools.defaults import getDefault, setDefault
from mojo.UI import UpdateCurrentGlyphView

print getDefault('glyphViewGridx')
print getDefault('glyphViewGridy')

setDefault('glyphViewGridx', 32)
setDefault('glyphViewGridy', 32)

UpdateCurrentGlyphView()
</code></pre>
<p dir="auto">Thanks, Thom</p>
]]></description><link>https://forum.robofont.com/topic/297/setdefault-updatecurrentglyphview</link><generator>RSS for Node</generator><lastBuildDate>Sat, 09 May 2026 13:10:40 GMT</lastBuildDate><atom:link href="https://forum.robofont.com/topic/297.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 15 Feb 2014 11:32:07 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to SetDefault &amp; UpdateCurrentGlyphView on Mon, 01 Jan 2018 12:48:29 GMT]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">I think I found a bug. When setting a default for the GlyphView and UpdateCurrentGlyphView, it won't be visible until I reopen the GlyphView.<br />
For now all I want is to set the grid. Maybe it can be done more simple? Here is my code.</p>
<pre><code class="language-python">from lib.tools.defaults import getDefault, setDefault
from mojo.UI import UpdateCurrentGlyphView

print getDefault('glyphViewGridx')
print getDefault('glyphViewGridy')

setDefault('glyphViewGridx', 32)
setDefault('glyphViewGridy', 32)

UpdateCurrentGlyphView()
</code></pre>
<p dir="auto">Thanks, Thom</p>
]]></description><link>https://forum.robofont.com/post/297</link><guid isPermaLink="true">https://forum.robofont.com/post/297</guid><dc:creator><![CDATA[thom]]></dc:creator><pubDate>Mon, 01 Jan 2018 12:48:29 GMT</pubDate></item><item><title><![CDATA[Reply to SetDefault &amp; UpdateCurrentGlyphView on Mon, 01 Jan 2018 12:47:57 GMT]]></title><description><![CDATA[<p dir="auto">he Thom</p>
<p dir="auto"><code>UpdateCurrentGlyphView()</code> just refreshes the glyph view, it ask to redraw. It will not update defaults / preferences</p>
<p dir="auto">You can update the defaults in all views by posting an preferences changed notification.</p>
<pre><code class="language-python">from lib.tools.notifications import PostNotification
PostNotification("doodle.preferencesChanged")
</code></pre>
<p dir="auto">similar to the ShapeTool see <a href="https://github.com/typemytype/RoboFontExtensions/blob/master/pixelTool/PixelTool.roboFontExt/lib/PixelTool.py#L109" rel="nofollow">https://github.com/typemytype/RoboFontExtensions/blob/master/pixelTool/PixelTool.roboFontExt/lib/PixelTool.py#L109</a></p>
<p dir="auto">good luck</p>
]]></description><link>https://forum.robofont.com/post/1154</link><guid isPermaLink="true">https://forum.robofont.com/post/1154</guid><dc:creator><![CDATA[frederik]]></dc:creator><pubDate>Mon, 01 Jan 2018 12:47:57 GMT</pubDate></item><item><title><![CDATA[Reply to SetDefault &amp; UpdateCurrentGlyphView on Sat, 15 Feb 2014 18:28:50 GMT]]></title><description><![CDATA[<p dir="auto">That does the trick like it should be ;)</p>
<p dir="auto">Thanks again Frederik!</p>
]]></description><link>https://forum.robofont.com/post/1155</link><guid isPermaLink="true">https://forum.robofont.com/post/1155</guid><dc:creator><![CDATA[thom]]></dc:creator><pubDate>Sat, 15 Feb 2014 18:28:50 GMT</pubDate></item></channel></rss>