<?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 copy&#x2F;paste behavior for custom contexts?]]></title><description><![CDATA[<p dir="auto">Hi Frederik,</p>
<p dir="auto">I love how copy-pasting a glyph renders it in different ways in different contexts – like how it prints out the glif data if you try to copy-paste to a text field.</p>
<p dir="auto">I’m wondering about modifying this behavior in special cases. Specifically, looking at improvements for word-o-mat I was wondering if it might be useful for the user to be able to copy-paste glyphs into the input text fields. (I’m not sure it’s actually a good idea, but some people may try to do that.) But then of course I would want the glyph <em>name</em> to be pasted, not the XML data (which is what currently happens, as the text field is identified as a text-only context, I guess).</p>
<p dir="auto">So I’m wondering whether it is (a) possible and (b) actually desirable/a good idea/good form to make the glyph paste itself as a name instead of the xml data in such a case?</p>
<p dir="auto">Thanks for your thoughts,<br />
Nina</p>
]]></description><link>https://forum.robofont.com/topic/373/modify-glyph-copy-paste-behavior-for-custom-contexts</link><generator>RSS for Node</generator><lastBuildDate>Sat, 18 Jul 2026 12:32:59 GMT</lastBuildDate><atom:link href="https://forum.robofont.com/topic/373.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 11 Apr 2015 13:37:28 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Modify glyph copy&#x2F;paste behavior for custom contexts? on Mon, 01 Jan 2018 16:15:30 GMT]]></title><description><![CDATA[<p dir="auto">Hi Frederik,</p>
<p dir="auto">I love how copy-pasting a glyph renders it in different ways in different contexts – like how it prints out the glif data if you try to copy-paste to a text field.</p>
<p dir="auto">I’m wondering about modifying this behavior in special cases. Specifically, looking at improvements for word-o-mat I was wondering if it might be useful for the user to be able to copy-paste glyphs into the input text fields. (I’m not sure it’s actually a good idea, but some people may try to do that.) But then of course I would want the glyph <em>name</em> to be pasted, not the XML data (which is what currently happens, as the text field is identified as a text-only context, I guess).</p>
<p dir="auto">So I’m wondering whether it is (a) possible and (b) actually desirable/a good idea/good form to make the glyph paste itself as a name instead of the xml data in such a case?</p>
<p dir="auto">Thanks for your thoughts,<br />
Nina</p>
]]></description><link>https://forum.robofont.com/post/372</link><guid isPermaLink="true">https://forum.robofont.com/post/372</guid><dc:creator><![CDATA[nina]]></dc:creator><pubDate>Mon, 01 Jan 2018 16:15:30 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph copy&#x2F;paste behavior for custom contexts? on Mon, 01 Jan 2018 16:19:08 GMT]]></title><description><![CDATA[<p dir="auto">He Nina</p>
<p dir="auto">Space Center already doest that, in all three input boxes. You could use that for Word-O-Mat... so it has support for pasting glif xml</p>
<pre><code class="language-python">from lib.UI.spaceCenter.glyphSequenceEditText import GlyphSequenceEditText
from vanilla import *

class Test:
    
    def __init__(self):
        
        self.w = Window((200, 100))
        
        # the only tricky thing is that it is optimized for the lowerlevel defcon font object...
        self.w.input = GlyphSequenceEditText((10, 10, -10, 22), CurrentFont().naked(), callback=self.inputChangedCallback)
        self.w.open()

    def inputChangedCallback(self, sender):
        print sender.get()

Test()
</code></pre>
<p dir="auto">FYI:</p>
<p dir="auto">RoboFont writes different representations to the pasteboard, any thing that is responding to a paste action can read their preferred representation.</p>
<p dir="auto">it is possible to add you're own representations if you subscribe to the paste notification, just a add or rewrite whatever you like :)</p>
<p dir="auto">see <a href="https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/PasteboardGuide106/Introduction/Introduction.html#//apple_ref/doc/uid/TP40008100-SW1" rel="nofollow">https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/PasteboardGuide106/Introduction/Introduction.html#//apple_ref/doc/uid/TP40008100-SW1</a></p>
]]></description><link>https://forum.robofont.com/post/1350</link><guid isPermaLink="true">https://forum.robofont.com/post/1350</guid><dc:creator><![CDATA[frederik]]></dc:creator><pubDate>Mon, 01 Jan 2018 16:19:08 GMT</pubDate></item><item><title><![CDATA[Reply to Modify glyph copy&#x2F;paste behavior for custom contexts? on Mon, 13 Apr 2015 11:58:57 GMT]]></title><description><![CDATA[<p dir="auto">Thanks Frederik. That’s a very useful start. I see it does not inherit/use the text attribute of the Vanilla EditText, which I need, but I guess I’ll look into making a subclass of my own ... maybe for the version after next ;)</p>
]]></description><link>https://forum.robofont.com/post/1351</link><guid isPermaLink="true">https://forum.robofont.com/post/1351</guid><dc:creator><![CDATA[nina]]></dc:creator><pubDate>Mon, 13 Apr 2015 11:58:57 GMT</pubDate></item></channel></rss>