Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Orion/Documentation/Developer Guide/Simple plugin example

< Orion‎ | Documentation‎ | Developer Guide
Revision as of 15:40, 5 May 2011 by Unnamed Poltroon (Talk) (created page, lots more to do)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This page explains how to write a plugin for Orion. It's intended for developers who want to extend Orion's functionality.

What's a plugin?

Just an html file

Before you start

Your plugin HTML file must include the following JavaScript dependencies:

  • OpenAjax: OpenAjaxManagedHub-all.js
  • Orion Provider API: plugin.js

The easiest way to satisfy these is to get orion-plugin.js, which is a minified file that includes both of them. Your plugin can then just include orion-plugin.js in a <script> tag, and you'll get everything you need.

Services

TODO

Examples

Here are some existing plugins we've written. View the source code to see how they work:

http://bokowski.github.com/format-js.html
Contributes a "Beautify JS" button to the editor toolbar by using the editorAction service type.
http://mamacdon.github.com/m6/uglify/uglify-plugin.html
Contributes an "Uglify JS" button to the editor toolbar byusing the editorAction service type.
http://orionhub.org/plugins/sampleCommandsPlugin.html
Contributes several sample actions to the Orion navigator by using the fileCommands service type.
http://orionhub.org/plugins/htmlSyntaxHighlightPlugin.html
Contributes syntax highlighting support for HTML files by using the ISyntaxHighlight service type.

See also

Back to the top