PDA

View Full Version : How to position the buttons in Ext.FormPanel?



evil_elf
28 Mar 2010, 8:42 AM
All buttons are as a list, first behind second.How arrange them in one line?


var exhibs = new Ext.FormPanel({
url: 'test.php',
renderTo: exhib_add,
frame: true,
title: '????????',
labelWidth: 1,
width: 540,
items: [
{
xtype: 'datefield',
name: 'date',
emptyText: '????'
},new Ext.form.ComboBox({
name: 'place_id',
store: places_store,
forceSelection:true,
minChars: 2,
typeAhead:true,
mode: 'local',
triggerAction: 'all',
width: 97,
displayField:'place_name',
hiddenName: 'place_id',
valueField: 'place_id',
emptyText:'???????',
renderTo: document.body
}),{
xtype: 'textfield',
name: 'exhib_name',
emptyText: '????????',
width: 300
}]
});
});

steffenk
28 Mar 2010, 12:49 PM
use a hbox layout
http://www.extjs.com/deploy/dev/docs/?class=Date&member=formatFunctions?class=Ext.layout.HBoxLayout

evil_elf
28 Mar 2010, 1:05 PM
Show me please an example of its use :-?

steffenk
28 Mar 2010, 1:12 PM
you should have more own initiative, at least with what you have downloaded in the examples
http://www.extjs.com/deploy/dev/examples/layout/hbox.html