PDA

View Full Version : padding Ext.form.TextField



PatrickS
6 Oct 2010, 6:42 AM
Hi,

For one field in my form I would like to bring the label and the inputfield closer together. I can manipulate the labelstyle and the input style, but I cant get them closre together. Does anyone know how I can do this? (without changing the general style, because it should only affect 1 textfield)

Patrick

Condor
6 Oct 2010, 6:56 AM
labelWidth and optionally also labelPad

laurentParis
6 Oct 2010, 6:58 AM
You need labelStyle to set padding-right to 0px



new Ext.FormPanel({
labelAlign: 'right',
labelSeparator: '',
labelPad: 0,
defaults: {
labelStyle: 'padding-right: 0px;' // << for all field, move it on one particular field if you prefer
},
...