<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to No_internal_or_system_editor</title><link>https://sourceforge.net/p/hpg-projects/wiki/No_internal_or_system_editor/</link><description>Recent changes to No_internal_or_system_editor</description><atom:link href="https://sourceforge.net/p/hpg-projects/wiki/No_internal_or_system_editor/feed" rel="self"/><language>en</language><lastBuildDate>Fri, 20 Jan 2023 12:18:28 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/hpg-projects/wiki/No_internal_or_system_editor/feed" rel="self" type="application/rss+xml"/><item><title>No_internal_or_system_editor modified by Hugh Greene</title><link>https://sourceforge.net/p/hpg-projects/wiki/No_internal_or_system_editor/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;This problem is typically encountered during a fresh install of&lt;br/&gt;
&lt;a class="" href="/p/hpg-projects/wiki/LateralGM/" title="wikilink"&gt;LateralGM&lt;/a&gt; on &lt;a class="" href="/p/hpg-projects/wiki/Linux/" title="wikilink"&gt;Linux&lt;/a&gt;, when the&lt;br/&gt;
user attempts to Edit a &lt;a class="" href="../sprite" title="wikilink"&gt;sprite&lt;/a&gt; subimage, a&lt;br/&gt;
&lt;a class="" href="../background" title="wikilink"&gt;background&lt;/a&gt; image, or a&lt;br/&gt;
&lt;a class="" href="../sound" title="wikilink"&gt;sound&lt;/a&gt;'s data. The user will click the button, and&lt;br/&gt;
the program will pause for a very brief moment, and then the program&lt;br/&gt;
will seem to behave as though the user never clicked the button.&lt;/p&gt;
&lt;p&gt;Note that this problem can be avoided entirely by following the&lt;br/&gt;
&lt;a class="" href="#Workaround" title="wikilink"&gt;#Workaround&lt;/a&gt; before ever attempting to edit&lt;br/&gt;
any images in LateralGM.&lt;/p&gt;
&lt;h2 id="stack-trace"&gt;Stack Trace&lt;/h2&gt;
&lt;p&gt;The keen user might notice the terminal will dump the following lovely&lt;br/&gt;
stack&lt;br/&gt;
trace:&lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;Exception in thread "AWT-EventQueue-0" java.lang.UnsupportedOperationException: no internal or system sprite editor
        at org.lateralgm.subframes.SpriteFrame$ImageEditor.start(SpriteFrame.java:1054)
        at org.lateralgm.subframes.SpriteFrame$ImageEditor.&amp;lt;init&amp;gt;(SpriteFrame.java:1042)
        at org.lateralgm.subframes.SpriteFrame.editSubimage(SpriteFrame.java:988)
        at org.lateralgm.subframes.SpriteFrame.handleToolbarEvent(SpriteFrame.java:834)
        at org.lateralgm.subframes.SpriteFrame.actionPerformed(SpriteFrame.java:819)
        at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2018)
        at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2341)
        at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
        at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
        at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:252)
        at java.awt.Component.processMouseEvent(Component.java:6504)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3321)
        at java.awt.Component.processEvent(Component.java:6269)
        at java.awt.Container.processEvent(Container.java:2229)
        at java.awt.Component.dispatchEventImpl(Component.java:4860)
        at java.awt.Container.dispatchEventImpl(Container.java:2287)
        at java.awt.Component.dispatchEvent(Component.java:4686)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
        at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4492)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
        at java.awt.Container.dispatchEventImpl(Container.java:2273)
        at java.awt.Window.dispatchEventImpl(Window.java:2713)
        at java.awt.Component.dispatchEvent(Component.java:4686)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:707)
        at java.awt.EventQueue.access$000(EventQueue.java:101)
        at java.awt.EventQueue$3.run(EventQueue.java:666)
        at java.awt.EventQueue$3.run(EventQueue.java:664)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
        at java.awt.EventQueue$4.run(EventQueue.java:680)
        at java.awt.EventQueue$4.run(EventQueue.java:678)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:677)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:211)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
Caused by: java.lang.UnsupportedOperationException: The EDIT action is not supported on the current platform!
        at java.awt.Desktop.checkActionSupport(Desktop.java:225)
        at java.awt.Desktop.edit(Desktop.java:300)
        at org.lateralgm.subframes.SpriteFrame$ImageEditor.start(SpriteFrame.java:1050)
        ... 40 more
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;The two unindented lines are the ones that tell the story:&lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;code&gt;UnsupportedOperationException: no internal or system sprite editor
Caused by: UnsupportedOperationException: The EDIT action is not supported on the current platform!
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;h2 id="explanation"&gt;Explanation&lt;/h2&gt;
&lt;p&gt;The Stack Trace Exception is just telling you that you have specified&lt;br/&gt;
that LGM should use an external sprite editor (the default behavior for&lt;br/&gt;
LGM), but your operating system/platform does not support the EDIT&lt;br/&gt;
action. This is a known Java bug&lt;br/&gt;
&lt;a class="" href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7035369" rel="nofollow"&gt;7035369&lt;/a&gt;&lt;br/&gt;
that affects Linux platforms (especially Debian-based).&lt;/p&gt;
&lt;p&gt;Unfortunately, the bug has been there for ages, and it doesn't seem like&lt;br/&gt;
any effort is being put into correcting it, so we have to provide a&lt;br/&gt;
workaround. Since there's not a nice way to figure out what your image&lt;br/&gt;
editor on Linux is (the nice way would have been the EDIT action...),&lt;br/&gt;
and we cannot assume that you have a specific editor installed (we used&lt;br/&gt;
to assume the GIMP, but Ubuntu stopped shipping with that, so now Ubuntu&lt;br/&gt;
pretty much doesn't have an image editor), which means that you, the&lt;br/&gt;
user, must specify a desired image editor.&lt;/p&gt;
&lt;h2 id="workaround"&gt;Workaround&lt;/h2&gt;
&lt;p&gt;LateralGM allows you to specify a desired resource editor in its&lt;br/&gt;
Settings/Preferences. Please see &lt;a class="" href="../Overriding_settings" title="wikilink"&gt;Overriding&lt;br/&gt;
settings&lt;/a&gt;. The properties that you would&lt;br/&gt;
wish to modify are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;externalBackgroundEditorCommand&lt;/li&gt;
&lt;li&gt;externalSpriteEditorCommand&lt;/li&gt;
&lt;li&gt;externalSoundEditorCommand&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;And a typical value for, say, Gimp, would be: &lt;code&gt;gimp %s&lt;/code&gt;&lt;/p&gt;
&lt;h2 id="long-term-solution"&gt;Long Term Solution&lt;/h2&gt;
&lt;p&gt;A long term solution is planned by simply providing an image editor with&lt;br/&gt;
LateralGM (similar to what Game Maker does). In order for it to be&lt;br/&gt;
included, however, it would need to meet several criteria.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It would need to be small in filesize. LateralGM is only 1-2 MB, and&lt;br/&gt;
    it seems ridiculous to include an image editor that is larger than&lt;br/&gt;
    LGM itself - which already rules out most of the existing image&lt;br/&gt;
    editors.&lt;/li&gt;
&lt;li&gt;It would need to be GNU GPL 3+ compatible, as this is the&lt;br/&gt;
&lt;a class="" href="../license" title="wikilink"&gt;license&lt;/a&gt; LGM is written in. This rules out&lt;br/&gt;
    several more image editors.&lt;/li&gt;
&lt;li&gt;It would need to be cross-platform, as LGM is cross-platform. A good&lt;br/&gt;
    way to achieve this would be to be written in Java.&lt;/li&gt;
&lt;li&gt;It is preferred that it is written in &lt;a class="" href="/p/hpg-projects/wiki/Java/" title="wikilink"&gt;Java&lt;/a&gt;, so&lt;br/&gt;
    that it can be completely internal, rather than having to launch an&lt;br/&gt;
    external program. This pretty much rules out the rest of them.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Seeing as we've pretty much ruled out every image editor in existence,&lt;br/&gt;
this leaves the final solution: build our own. And that's exactly what&lt;br/&gt;
we've proposed. Enter &lt;a class="" href="../JEIE" title="wikilink"&gt;Java Easy Image Editor (JEIE)&lt;/a&gt;.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Hugh Greene</dc:creator><pubDate>Fri, 20 Jan 2023 12:18:28 -0000</pubDate><guid>https://sourceforge.netc4aa9bdb47eb177e240686ef848812079a5f4cc3</guid></item></channel></rss>