GWT UI Layout

180 views
Skip to first unread message

Santosh

unread,
Jun 12, 2012, 1:10:19 AM6/12/12
to Google Web Toolkit
We wanted to design a layout in GWT which has quite a lot of small
small sections on screen. Basically it has a left menu, header,
footer, main content area with lot of sub sections which can be closed
by user in case if he does not want to see them. Then remaining
content section should get adjusted automatically. We are using GWT
Platform. I am in doubt, whether DockLayoutPanel suits for this or
not, because, it has to be must more flexible. Apart from that, I
didnt get any good layout examples. Can we achieve this using GWT
panels or we have to manually do it using div in module html file?

Thomas Broyer

unread,
Jun 12, 2012, 6:35:16 AM6/12/12
to google-we...@googlegroups.com
How about the LayoutPanel?
The advantage of LayoutPanel is that it can animate smoothly between states.

Santosh

unread,
Jun 12, 2012, 8:24:07 AM6/12/12
to Google Web Toolkit
Does layoutpanel give that kind of flexibility to build complex
structures? I heard this is the simplest panel upon which others are
built

Cristian Rinaldi

unread,
Jun 12, 2012, 8:41:52 AM6/12/12
to google-we...@googlegroups.com
I have built complex structures using LayoutPanel, gives much flexibility. 
Also as Thomas said, you can animate transitions. 

By example: 
public void setDefaultLayout () {   
  ...   
  ...   
  mainLayout.setWidgetLeftWidth (logo, 0, TCP 100, TCP);   
  mainLayout.setWidgetTopHeight (logo, 0, PCT, NORTH_HEIGHT, PX);    

  mainLayout.setWidgetLeftWidth (navigation, 0, TCP 100, TCP);          mainLayout.setWidgetTopHeight (navigation, NORTH_HEIGHT, PX 38, PX);   
  ...   
  ...   
  mainLayout.animate (500); 

You are responsible for positioning the internal widget or panels.

A.U.S Cristian Rinaldi


2012/6/12 Santosh <santos...@darkhorseboa.com>
--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.


Santosh

unread,
Jun 12, 2012, 9:00:21 AM6/12/12
to Google Web Toolkit
Will try to use and see if it can help. Thanks

On Jun 12, 5:41 pm, Cristian Rinaldi <csrina...@gmail.com> wrote:
> I have built complex structures using LayoutPanel, gives much flexibility.
> Also as Thomas said, you can animate transitions.
>
> By example:
> public void setDefaultLayout () {
>   ...
>   ...
>   mainLayout.setWidgetLeftWidth (logo, 0, TCP 100, TCP);
>   mainLayout.setWidgetTopHeight (logo, 0, PCT, NORTH_HEIGHT, PX);
>
>   mainLayout.setWidgetLeftWidth (navigation, 0, TCP 100, TCP);
>  mainLayout.setWidgetTopHeight (navigation, NORTH_HEIGHT, PX 38, PX);
>   ...
>   ...
>   mainLayout.animate (500);
>
> }
>
> You are responsible for positioning the internal widget or panels.
>
> A.U.S Cristian Rinaldi
>
> 2012/6/12 Santosh <santosh.ku...@darkhorseboa.com>

Vasu

unread,
Jun 14, 2012, 5:40:50 AM6/14/12
to google-we...@googlegroups.com
Rather than using any existing layout panel I would suggest you to use uiBinder by using HTMLPanel widget to design your root lay out and create the place holder using uifield which you can manipulate through your respective class of uibinder. That way you get a flexibility of having html and styling done in pure html manner which is even more readable and maintainable.

-Vasu.
> > To post to this group, send email to google-web-toolkit@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-toolkit+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages