Readonly and disabled inconsistency

I want to prevent the user from being able to edit any type of inputs within a form (input, select, radio, checkbox etc.). Applying readonly works for standard inputs but for calendars still allows the user to select a date via the mouse. This is inconsistent with the standard inputs and with the grid (ro columns are readonly even for date columns). If I initialize the form and use ‘disabled’ instead of ‘readonly’ I get the behaviour I desire but the styling is not correct. I want all of the inputs to be readonly / not editable but not be greyed out like they are disabled. I can use ‘disabled’ instead of ‘readonly’ and add some css rules to give the readonly styling but then I cannot differentiate between truly disabled inputs and readonly inputs.

Am I missing something?

There is no any custom logic for readonly for calendar or colorpicker. Readonly simply sets “readonly” attr, for calendar you can try to use wrapper for _show function, i.e.

var myForm = new dhtmlXForm(...); var myCalendar = myForm.getCalendar(name); myCalendar._show2 = myCalendar._show; myCalendar._show = function(){ if (some_condition != true) return; this._show2.apply(this,argumetns); // call native logic }