简体   繁体   English

在列布局面板中水平滚动

[英]Horizontal scrolling in a column layout panel

I am troubled with this issue of horizontal scrollbar not apprearing in my Panel. 我对水平滚动条在面板中不显示的问题感到困扰。 My application is put up as 6 panels in column layout. 我的应用程序按列布局放置为6个面板。 Each panel is 250px in width. 每个面板的宽度为250px。 The issue is that the 6th panel gets displayed under the 5th panel rather than on its side!! 问题是第六面板显示在第五面板下方,而不是在侧面!

How do I display the last panel on the right side rather than under the 5th? 如何在右侧而不是在5号下方显示最后一个面板? Here is my code snippet: 这是我的代码段:

var appPanel = new Ext.Panel({
    applyTo: document.body,
    autoWidth: true,
    autoScroll: true,
    title: 'Users & Groups Panel',
    layout:'column',
    items: [{
        items: p1
    },{
        items: p2
    },{
        items: p3
    },{
        items: p4
    },{
        items: p5
    },{
        items: p6
    }]
});

Each panel is declared with a width of 250px as given below: 每个面板的宽度声明为250px,如下所示:

var p1= new Ext.Panel({
    frame:false,
    width:250,      
    collapsible:false,
    title:'Prime Users',
    items: ...
});

ColumnLayout is defined as having floated columns, so they'll always wrap if you define fixed widths that exceed the overall container width. ColumnLayout被定义为具有浮动列,因此,如果您定义的固定宽度超过了容器的整体宽度,它们将始终被包装。 You should either use percentage widths instead or use a different layout style (or override the layout's default CSS to do what you need). 您应该改用百分比宽度或使用其他布局样式(或覆盖布局的默认CSS来完成所需的操作)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM