Correct way to create hierarchical menus in toolbar?

Having trouble deploying Oxygen XML Web Author? Got a bug to report? Post it all here.
wbrisett
Posts: 38
Joined: Thu Feb 21, 2013 11:44 pm

Correct way to create hierarchical menus in toolbar?

Post by wbrisett »

We're using the custom version of oXygen for web provided as part of the Ixiasoft product. By taking a few things I had done in oXygen standalone, I was able to make changes to the framework. However, I'm confused about one thing, that is, how do I change things so that the number.xxxx values are all grouped in the toolbar? These actions put them as individual items which I don't want. It it simply a matter for creating a parent item where all the options are then children of that item?

Current:

Code: Select all

      <toolbar>
        <separator/>
        <addAction id="insert.note"/>
        <addAction id="number.any"/>
        <addAction id="number.binary"/>
        <addAction id="number.hex"/>
        <removeAction id="bold"/>
        <removeAction id="underline"/>
        <removeAction id="italic"/>
      </toolbar>
What I want is all the number.any, number.binary, and number.hex all available in the toolbar but something like this (which may not work, but illustrates what I want).

Code: Select all

<toolbar>
<separator/>
        <addAction id="insert.note"/>
	<addAction id="number">
		<addAction id="number.any"/>
        	<addAction id="number.binary"/>
        	<addAction id="number.hex"/>
        </addAction>
        <removeAction id="bold"/>
        <removeAction id="underline"/>
        <removeAction id="italic"/>
      </toolbar>
Thanks!
Wayne
Bogdan Dumitru
Site Admin
Posts: 142
Joined: Tue Mar 20, 2018 5:28 pm

Re: Correct way to create hierarchical menus in toolbar?

Post by Bogdan Dumitru »

Hello Wayne,

To add actions in a separate group from a Framework Extension Script (.exf) try using the "group" element, like exemplified in the Framework Extension Script File documentation topic:

Code: Select all

<group name="New group">
  <addAction id="insert.note"/>
  <addAction id="insert.table"/>
</group>
Bogdan Dumitru
http://www.oxygenxml.com
wbrisett
Posts: 38
Joined: Thu Feb 21, 2013 11:44 pm

Re: Correct way to create hierarchical menus in toolbar?

Post by wbrisett »

Bogdan, thanks! I missed the <group> element when I looked at that. I do have a question though and I don't see it in the documentation. Is there a way with the group to add add an icon to that group? Right now in each individual actions there's an area to set an icon, I can't see anything in the documentation itself about this, but I would think there should be a way to do this, but I can't seem to find that.
mihaela
Posts: 490
Joined: Wed May 20, 2009 2:40 pm

Re: Correct way to create hierarchical menus in toolbar?

Post by mihaela »

Hello,

The group element has two attributes that refer to images: smallIconPath and largeIconPath. The first one is used in the toolbar, and the second one is in the menus. If you edit the exf in Oxygen XML Editor you can use the content completion to see the available attributes and elements.

Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
Post Reply