<?xml version="1.0" encoding="utf-8"?>
<klayout-macro>
 <description/>
 <version/>
 <category/>
 <prolog/>
 <epilog/>
 <doc/>
 <autorun>true</autorun>
 <autorun-early>false</autorun-early>
 <priority>0</priority>
 <shortcut/>
 <show-in-menu>false</show-in-menu>
 <group-name/>
 <menu-path/>
 <interpreter>ruby</interpreter>
 <dsl-interpreter-name/>
 <text>module MpluginEC
 
include RBA

class PluginECFactory &lt; PluginFactory
  def initialize
    register(100000, "plugin_extern", "External\nControl")
  end
  def create_plugin(manager, root, view)
    return PluginEC.new
  end
end

class PluginEC &lt; Plugin
  def mouse_moved_event(p, buttons, prio)
    if prio
      # Set the cursor to cross if our plugin is active.
      set_cursor(RBA::Cursor::Cross)
      true
    end
    # Returning false indicates that we don't want to consume the event.
    false
  end
end

PluginECFactory.new

end
</text>
</klayout-macro>
