Wijmo UI for the Web
data Option
wijmo.ribbon.wijribbon Namespace > options type : data Option

Default value: null

Using this option to create customize ribbon: ribbon tabs, groups, buttons. Can define the ribbon data like this: var ribbonData = []; // format tab definition ribbonData[0] = { id: "format", text: "format", groups:[ // Actions group definition { id:"Actions", text: "Actions", css: "wijmo-wijribbon-actions", // group's buttons definition buttons:[ //big button definition: save { name: "save", tip: 'Save', text: 'Save Button', css: "wijmo-wijribbon-save", buttonType: "bigButton", action: function (e) { alert("Save"); } }, //redo and undo in one set [ { name: "undo", tip: 'Undo', css: "wijmo-wijribbon-undo", buttonType: "button" }, { name: "redo", tip: 'Redo', css: "wijmo-wijribbon-redo", buttonType: "button" } ], //preview and cleanup in one set [ { name: "preview", tip: 'Preview', css: "wijmo-wijribbon-preview" }, { name: "cleanup", tip: 'Clean up', css: "wijmo-wijribbon-cleanup" } ] ] }]; Now the supported button's type is: "button", "buttonWithText", "bigButton", "checkbox", "dropdownButton", "radio", "splitButton". User can define button's text, tooltip, class and click function; if some buttons in one group, put them in array. Some details refer the customizeribbonbydata.html and customizesimpleribbonbydata.html.

Syntax
$(function () {
    
    // Get value
    var returnsValue; // Type:  object
    returnsValue = $(".selector").wijribbon("option", "data");
    
    // Set value
    var newValue; // Type:  object
    $(".selector").wijribbon("option", "data", newValue);
        
});
var data : object;
See Also

Reference

options type
wijribbon jQuery Widget