EXT 佈局中縮短label與field之間距離的方法

主要是採用一個插件 FieldLabeler 在ext-3.3.1\examples\ux路徑下。

[align=left]var templatePanel = new Ext.Panel({
region: 'north',
height: 40,
width: 600,
bodyStyle: 'padding:8px 0px',
labelWidth: 55,
layout: {
type: 'hbox',
pack: 'center'
},
defaults: {
xtype: 'textfield'
},
items:[{
fieldLabel: '模板名稱',
plugins: [Ext.ux.FieldLabeler],
name: 'name'
},{
xtype: 'combo',
width: 150,
ieldLabel: '模板類型',
plugins: [Ext.ux.FieldLabeler],
editable: false,
forceSelection:true,
store: new Ext.data.SimpleStore({
fields: ["value","status"],
data: [["0","直播頻道"],["1","虛擬頻道"]]
}),
mode: "local",
triggerAction: "all",
displayField : "status",
valueField: "value",
hiddenName : "type",
name: "type",
allowBlank: false
},{
fieldLabel:"備註",
plugins: [Ext.ux.FieldLabeler],
name: "description"
}]
});[/align]
發佈了54 篇原創文章 · 獲贊 0 · 訪問量 3094
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章