Separator

This is a control that adds a line separating items/groups of items from each other.

DHX Ribbon with separators

Adding Separator

A separator can be added between menu options:

{
    type:"navItem", value:"File", items:[
        { type:"menuItem", value:"Option 1" },
        { type:"menuItem", value:"Option 2" },
        { type:"separator"},
        { type:"menuItem", value:"Option infinite" }
    ]
}

Attributes

Separator can have two attributes:

  • type - (string) the item type, set it to "separator"
  • id - (string) the ID of a control, automatically generated if you do not set it

Showing/hiding Separator

You can hide and show Separator with the methods of Ribbon:

ribbon.showItem(id);
ribbon.hideItem(id);
Back to top