[oXygen-user] AuthorMode, open selected word in default app (browser)

Oxygen XML Editor Support support at oxygenxml.com
Mon Mar 24 09:29:26 CDT 2014


Hi Andreas,

For the first use case you could probably use the predefined operation 
called 
"ro.sync.ecss.extensions.commons.operations.ShowElementDocumentationOperation" 
which takes an URL parameter that can be set by you to the value:

> http://www.perseus.tufts.edu/hopper/morph?l=${selection}&la=la

where the "${selection}" editor variable will be expanded to the text 
selected in the Author visual editing mode.

If you need anything more complex, you can create your own custom Java 
operation extending "ro.sync.ecss.extensions.api.AuthorOperation" and 
use our API.
The Java code for both 
"ro.sync.ecss.extensions.commons.operations.OpenInSystemAppOperation" 
and 
"ro.sync.ecss.extensions.commons.operations.ShowElementDocumentationOperation" 
should be in our Author SDK project:

> http://www.oxygenxml.com/oxygen_sdk.html#XML_Editor_Authoring_SDK

Regards,
Radu

Radu Coravu
<oXygen/>  XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com

On 3/24/2014 4:13 PM, Andreas Wagner wrote:
> Dear list,
>
> I am working on an author mode/document type framework and I would like
> to allow my users to select a word and open a browser with the selected
> word at some place in the url. (like e.g.
> http://www.perseus.tufts.edu/hopper/morph?l=MYFUNNYWORD&la=la).
>
> Can I achieve this with the
> ro.sync.ecss.extensions.commons.operations.OpenInSystemAppOperation
> operation, and if so, what should its parameters be?
>
> (Ideally, a somewhat similar command could open a default link for the
> current document, the ID of which it would read from some XPath. E.g.
> google for the title and author of the current document.)
>
>
> Thank you,
>
> Andreas
>
>
>


More information about the oXygen-user mailing list