1. #1
    Ext User
    Join Date
    Jul 2010
    Posts
    10
    Vote Rating
    0
    spindelvav is on a distinguished road

      0  

    Question formPanel and gridPanel in panel, manage height?

    formPanel and gridPanel in panel, manage height?


    Hi. I'm new to extJS, and pretty new to web programming in general.

    Am now working on a small MapFish-app, based on the mapfish search demo, and am using a similiar layout.
    The layout hierarchy looks something akin to this:
    Viewport -layout:'border'
    ->BoxComponent - region:'north' (Only component rendered unto a <div>)
    ->gx_mappanel -region:'center'

    ->panel - region:'east', layout:'border'
    -->formPanel -region:'center'
    -->GridPanel -region:'south'

    The issue is that any 'height' or 'width' values set for the formPanel appear ignored, and if it is given enough space it covers the whole eastern area (vertically). If the gridPanel is given a height, it keeps that height no matter how the window is resized, so if the screen res. or window size gets small enough vertically, the formpanel disappears. Ideally, I'd wish for the opposite effect. If I let the eastern panel use a 'fit' layout, the gridPanel doesn't show up, no matter if a size: property is set for it.

    To be more precise I'd like to see the formpanel keeping its minimum size no matter what, and the gridpanel filling the (vertical) space remaining depending on the window size. (The width of the eastern panel appears decided by the combined width of the gridPanels columns).

    Thanks for your patience reading that, and if this has indeed been asked before - don't hesitate to point me in that direction.

    Cheerios,

  2. #2
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    95
    Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of

      0  

    Default


    The center region always gets the remaining size not taken by north, south, east and west regions.

    You should make the formPanel region:'north' and the grid region:'center'.

  3. #3
    Ext User
    Join Date
    Jul 2010
    Posts
    10
    Vote Rating
    0
    spindelvav is on a distinguished road

      0  

    Default


    I see.

    Worked well, many thanks!

Similar Threads

  1. Replies: 8
    Last Post: 28 May 2009, 1:13 PM
  2. Grid Panel auto height and max height
    By kellyt in forum Ext 2.x: Help & Discussion
    Replies: 3
    Last Post: 6 Oct 2008, 11:04 PM
  3. Tie the grid height to the panel height??
    By bhaidaya in forum Ext 2.x: Help & Discussion
    Replies: 6
    Last Post: 26 Mar 2008, 2:11 PM
  4. [Ext 2.0] formpanel and gridpanel nested inside panel
    By mdissel in forum Ext 2.x: Help & Discussion
    Replies: 3
    Last Post: 11 Jul 2007, 12:32 PM

Thread Participants: 1