extjs: TextField/Field 100% width








new Ext.FormPanel({
labelWidth: 75,
autoWidth: true,
items: [{
xtype: 'textfield',
fieldLabel:'Name',
anchor:'100%'
}]
}


Note:

1. The container component set autoWidth to true

2. The TextField item set the anchor value


anchor : 'width height'
exemple:
anchor:'100% 98%'
or
anchor:'-29 -10'//(bodycontentwidth - 29, bodycontentheight - 10)





No comments:

Post a Comment