Ribbon Bar - can it be hidden or disabled entirely

Is it possible to either hide the ribbon bar or disable it completely.

This is so that the user cannot click on any controls at all under certain circumstances.


Unfortunately there is no such possibility.

Hi Everyone
This turned out to be quite easy to do so I have shared a snippet here for anyone else that may want to do it.

What it does is that

  • when you call setMainRibbon(false) it records the status of all of the controls on the ribbon
    and then disables them. Note it does not touch blocks or groups or text items.
  • when you call setMainRibbon(true) it restores the items to their previous state.

note: dontTouch is a list of items that you never want disabled.

I hope this helps someone.

var ribbonStates = new Array();
var ribbonDisplayed = true;

// Enables or disables all buttons on the mainRibbon bar.
function setMainRibbon(enable) {
            var dontTouch =  ['item1','item5','item13'];
		if(mainRibbon != null && !ribbonDisplayed){
			ribbonDisplayed = true;
				var control = mainRibbon._items[item.id];
				if(item.disable == true)
		if(mainRibbon != null && ribbonDisplayed){
			ribbonDisplayed = false;
			ribbonStates = [];
			var keys = Object.keys(mainRibbon._items);
				var item = mainRibbon._items[id];
				if(item.type != undefined && item.type != "group" && item.type != "block" && item.type != "text"){
					if(!dontTouch.includes(id) ){
						ribbonStates.push ({
							id: item.id,
							disable: item.conf.disable