两种方式:
按钮居中方式1(默认为底部居中,此种方式button不属于items : [])
{
buttonAlign : 'center',
buttons : [{
xtype : 'button',
text : '添加待办事件',
border : false,
width : 100,
height : 30,
name : 'addBacklog',
action : 'addBacklog'
}],
items : [{},{},{},……]
}
按钮居中方式2(此种方式button属于items : [])
{
layout : {
type : 'vbox',//布局选择vbox
align : 'center'
},
items:[{
xtype : 'button',
text : '添加待办事件',
name : 'addBacklog'
action : 'addBacklog'//可以根据action或者name来识别获取到此button组件
}]
}