Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/extjs/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/vb.net/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Button ExtJS按钮对齐_Button_Extjs_Layout - Fatal编程技术网

Button ExtJS按钮对齐

Button ExtJS按钮对齐,button,extjs,layout,Button,Extjs,Layout,在ExtJs面板按钮中,我想创建两行按钮,如下所示 b1 b2 b3 b4 b5 b6 默认情况下,它是在单行中创建按钮。b1 b2 b3 b4 b5 b6 如何设置面板中按钮的布局 我试过buttongroup,效果很好。但我只是想知道我们是否能做布局 谢谢。嗯,您可以使用一个有两个面板的面板,每个面板包含三个按钮 您可以使用表或列布局或hbox布局将它们对齐到列中 例如: Ext.create("Ext.Panel", { items: [{ layout: {

在ExtJs面板按钮中,我想创建两行按钮,如下所示

b1 b2 b3

b4 b5 b6

默认情况下,它是在单行中创建按钮。b1 b2 b3 b4 b5 b6

如何设置面板中按钮的布局

我试过buttongroup,效果很好。但我只是想知道我们是否能做布局


谢谢。

嗯,您可以使用一个有两个面板的面板,每个面板包含三个按钮

您可以使用表或列布局或hbox布局将它们对齐到列中

例如:

Ext.create("Ext.Panel", {
   items: [{ 
        layout: {
          type: 'hbox',
          align: 'stretch'
        },
        items: [b1, b2, b3] // buttons should have a width or flex specified
   }, { 
        layout: {
          type: 'hbox',
          align: 'stretch'
        },
        items: [b4, b5, b6]
   }]
});
您可以将此面板作为项目放置在工具栏中


查看布局和示例

感谢您提供的链接。。。我使用了3列的表格布局。