Two Laptop Bag*
The moose likes GWT and the fly likes TabLayoutPanel auto height grow in gwt2.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "TabLayoutPanel auto height grow in gwt2.0" Watch "TabLayoutPanel auto height grow in gwt2.0" New topic
Author

TabLayoutPanel auto height grow in gwt2.0

Nilesh Pat
Ranch Hand

Joined: Mar 01, 2010
Posts: 46
hi,
i am using TabLayoutPanel in GWT2.0
i have some widgets added in it. which get added in TabLayoutPanel dynamically.
but when new widget get added TabLayoutPanel doesn't grow. as we have to specify it's height and width which then get fixed.

i am badly struck here as i want tab panel in my application.

is there any other way???
or can we increase height and width dynamically???


Regards,
Nil
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10170
    
    8

but when new widget get added TabLayoutPanel doesn't grow

What do you mean by grow? What do you expect to happen when you add the widget.

[How to ask questions] [Donate a pint, save a life!] [Onff-turn it on!]
Nilesh Pat
Ranch Hand

Joined: Mar 01, 2010
Posts: 46
thank you for your replay,

grow means, TabLayoutPanel should increase it's height accordingly the widgets added...

i am using TabLayoutPanel in gwt2.0.


some of my code in Widget.ui.xml

<gwt:TabLayoutPanel ui:field="searchTab"
barHeight="25" barUnit="PX" height="16PC" width="50PC">
<gwt:tab>
<gwt:header>Search</gwt:header>
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10170
    
    8

This is strange. I usually use DecoratedTabPanel and have not encountered this problem before.
Could you please post SSCCE code which we can try out?
Nilesh Pat
Ranch Hand

Joined: Mar 01, 2010
Posts: 46
i was previously using gwt 1.6
in which i was using DecoratedTabPanel which was working properly.
but now i am migrating it in gwt2.0
in which i can't use it. So i am using TabLayoutPanel.

code in Widget.ui.xml is,

<gwt:TabLayoutPanel ui:field="searchTab"
barHeight="25" barUnit="PX" height="16PC" width="50PC">
<gwt:tab>
<gwt:header>Search</gwt:header>
<gwt:VerticalPanel ui:field="fltVertPanel">
<gwt:FlexTable ui:field="flexTable2"></gwt:FlexTable>
</gwt:VerticalPanel>
</gwt:tab>
</gwt:TabLayoutPanel>



and in java file,

@UiField
TabLayoutPanel flightSearchTab;

@UiField
FlexTable flexTable2;

@UiField
VerticalPanel fltVertPanel;


my flex table contains all textboxes and all which get added dynamically on clicking some buttons
which increase height. but as height of TabLayoutPanel does not increase.
it get invisible.

so i want to increase height of TabLayoutPanel also on run time.

Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10170
    
    8

Looks like you are using the UI builder. Don't know about it. Sorry.
My current project uses 2.0 and I can use DecoratedTabPanel. I don't know what problem you are facing because of 2.0.
Nilesh Pat
Ranch Hand

Joined: Mar 01, 2010
Posts: 46

i am using GWT 2.0.3
As i search for it also, in UI builder it's difficult to add a Decorated tab panel. so i was using TabLayoutPanel.
but as i said early it is giving problem in auto height.

so now what i done is,
i am using VerticalPanel in UiBinder.
and added DecoratedTabPanel in VerticalPanel in java file not in UiBinder
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: TabLayoutPanel auto height grow in gwt2.0
 
Similar Threads
GWT2.0 released
Simple Programming exercise
Tiles problem: left menu area is not growing in length as the number of content lines grows
Height and Width proportional algorithm?
How to set layout_height of a spinner in code dynamically