Mark Derricutt wrote: > > Hiya - I'm looking at add some scripts to XXE to automate and make easier > some of the more routine things I do when writing documents, I've > downloaded the BSH scripting plugin files but havn't installed them yet. > > I noticed there wasn't any documentation, does anyone have any simple > example scripts showing demostrating how to insert elements into the current > document, or adding a toolbar/menuitem/shortcut? > > Is there a public API at all?
Yes, it is the public Java API (download developer's documentation from http://www.xmlmind.com/xmleditor/download.shtml ). It can be used directly from BeanShell or JavaScript. For now, extending XXE using scripting is not promoted at all (for example, there is no sample scripts). Two reasons for that: [1] Scripting engines are slow to the point of being almost unusable (XXE is developed on PII 400Mhz machines!). This is true for BeanShell. This is less true for (Rhino) JavaScript. This could be false for Jython (no scripting plug-in yet). [2] The Java API is too low-level for writing nice scripts. We intend to define a very high-level API for at least one of the scripting languages (we'll probably start with JavaScript). This high-level API will be comparable to the APIs exposed by Web browsers. In summary, scripting XXE today is technically feasible but in practice we do not recommend doing that. For now, we recommend extending XXE in Java. Note that once you have developed your extension, integration is done using configuration files. That is, defining toolbar, menuitem, shortcut does not require programming at all. Please read the Power User's Guide to ( http://www.xmlmind.com/xmleditor/_distrib/docs/poweruser/index.html ) learn more about this. See also macro-commands which can be used to extend XXE without programming. http://www.xmlmind.com/xmleditor/_distrib/docs/poweruser/ar01s04s02.html#macro

