specified inputWidth is being reduced by 4

DHTMLx ver 413, ‘web’ skin

When specifying a non-auto “inputWidth” property for a type: “input”, the rendered control has width set to 4 less than specified. For example,

inputWidth: 25

results in dom with style=“width: 21px;”

Is this some attempt to account for assumed padding? How can I get the actual width specified?

Hello
Please, send us completed demo on support@dhtmlx.com with a link to this topic
docs.dhtmlx.com/auxiliary_docs__ … pport.html

You can see the issue in your own samples:

dhtmlx.com/docs/products/dhtmlxF … bject.html

the form contains:

{type: "settings", position: "label-left", labelWidth: 130, inputWidth: 120}

and yet the input elements have, for example the ‘login’ input:

<input class="dhxform_textarea" name="sbZzTfLpaCmV" id="ZzblNXbCNpuL" type="TEXT" style="width: 112px;">

We manage to reproduce the issue. We will inspect it

Hi

that because of paddings and borders. different browsers render this in ifferent ways, so form has inner mechanism called dimfix which determine how to reduce control’s width.


Thanks for the explanation, and especially the mention of dimfix so that I can examine the code and really understand what’s happening. Your support is very helpful.