Page 1 of 1

Change Oxygen Toolbar Menu with any custom condtion

Posted: Thu Jan 11, 2018 5:30 pm
by jerryjames
Need to change the value coming on the menu based on some custom condition.
Currently, the menu details have been added to oxygen framework file.
Is there anyway to change the name in menu dynamically.

Re: Change Oxygen Toolbar Menu with any custom condtion

Posted: Thu Jan 11, 2018 5:36 pm
by Radu
Hi Jerry,

The action names added in the framework are static, they cannot be changed depending on a certain condition, change in the document.
One possibility would be to implement an Oxygen Java-based workspace access plugin:

https://www.oxygenxml.com/doc/versions/ ... lugin.html

Such a plugin receives a reference to the main Oxygen Java Swing-based menu and it can also add various listener to detect when XML documents are opened, or caret listeners in opened documents.

Regards,
Radu