Creating a table toolbar
In our latest release (Xopus 4.2), we've added support for table editing commands in the toolbar of Xopus. Using this toolbar, you can for example insert new colums or rows, move and delete them and do things like merging and splitting cells.
To enable this toolbar for your users, we have created a number of commands you can use from within your toolbar configuration. Here's an example of how to add the most common table functions to the toolbar:
<x:overlay xmlns="http://xopus.com/2009/lui">
<toolbar-group id="TableToolbarGroup" after="MoveGroup" haveAllCommandsAvailable="false">
<toolbar-button command="InsertTableColumnBeforeCommand"/>
<toolbar-button command="InsertTableColumnAfterCommand"/>
<toolbar-button command="InsertTableRowBeforeCommand"/>
<toolbar-button command="InsertTableRowAfterCommand"/>
<separator/>
<toolbar-button command="DeleteTableColumnCommand"/>
<toolbar-button command="DeleteTableRowCommand"/>
<separator/>
<toolbar-button command="MoveTableColumnLeftCommand"/>
<toolbar-button command="MoveTableColumnRightCommand"/>
<toolbar-button command="MoveTableRowUpCommand"/>
<toolbar-button command="MoveTableRowDownCommand"/>
<separator/>
<toolbar-button command="MergeTableCellUpCommand"/>
<toolbar-button command="MergeTableCellRightCommand"/>
<toolbar-button command="MergeTableCellDownCommand"/>
<toolbar-button command="MergeTableCellLeftCommand"/>
<separator/>
<toolbar-button command="SplitTableCellUpCommand"/>
<toolbar-button command="SplitTableCellRightCommand"/>
<toolbar-button command="SplitTableCellDownCommand"/>
<toolbar-button command="SplitTableCellLeftCommand"/>
</toolbar-group>
</x:overlay>
The complete list of available commands is: ChangeTableCellCommand, ChangeTableColumnCommand, ChangeTableRowCommand, DeleteTableColumnCommand, DeleteTableRowCommand, InsertTableBodyCommand, InsertTableColumnAfterCommand, InsertTableColumnBeforeCommand, InsertTableFooterCommand, InsertTableHeaderCommand, InsertTableRowAfterCommand, InsertTableRowBeforeCommand, MergeTableCellDownCommand, MergeTableCellLeftCommand, MergeTableCellRightCommand, MergeTableCellUpCommand, MoveTableColumnLeftCommand, MoveTableColumnRightCommand, MoveTableRowDownCommand, MoveTableRowUpCommand, SplitTableCellDownCommand, SplitTableCellLeftCommand, SplitTableCellRightCommand, SplitTableCellUpCommand
- Developer Blog
- › Creating a table toolbar