I have already tried it. But the problem with the CentreLayout is that it aligns horizontally correctly, but in vertical direction, it contracts the page to a relatively small stripe at the top of the browser screen. So it does not work correctly.
More closely, my layout hierarchy is the following:
1.viewport - centrelayout
1.1.contentpanel - fitlayout
220.127.116.11.contentpanel - borderlayout - called mainview
18.104.22.168.1.verticalpanel (on the west)
22.214.171.124.2.contentpanel (in the centre)
In case of using a centrelayout, the content below the toolbar becomes invisible, perhaps because mainwiew has no exact height, it is expected to occupy the free region entirely, but unfortunatelly, it does not.
If I removed the centerlayout, the page displayed correctly, but it is not aligned to the centre.
Last edited by ninja; 11 Sep 2008 at 11:37 PM.
Reason: Lost indentation
yes, you would need to size the panel for center layout to work - another option is to just use a normal table layout and size the table cell yourself... (center layout is just a table layout without any sizing - its 100%)
I have a very similar problem. I'd need a layout practically the same as the extjs.com layout: fixed width content centered on the page, with a header, body and footer band, the header and footer fixed height, the body vertically stretching to the wishes of the actual content -- i.e. the most common web page layout.
Would it be possible to create an "official" demo/sample that achieves this with the best performance? Since this is a very common use case, I think it would be to the benefit of the whole community.
An additional issue is that I'd like to use a Table in the body and would like that table to grow/shrink accourding to the number of actual rows ;-)