I found a solution that may point to the problem.  The following works:

               Scheduler.get().scheduleDeferred(new Command() {
                    public void execute () {
                     RootLayoutPanel.get().forceLayout();
                    }

Previously, I was doing the forceLayout (at various levels) after
everything was built.  That didn't work, but if I give JavaScript a chance
to catch up it does!  Note that it also works if I forceLayout at a lower
level rather than the root.

I don't know if this is a hack simply indicating a different problem I
have, or if it is a worst-case / works-no-matter-what way to do it.

Hope this is helpful to others.

Blake



On Thu, Feb 20, 2014 at 4:24 PM, Blake McBride <blake1...@gmail.com> wrote:

> Greetings,
>
> I think over the last year I have spent a good two to three solid weeks
> messing with forceLayout().  I just can't seem to get it straight, and
> then, when I think I do, it only works for some browsers and works
> differently on others.
>
> The specific problem I have now involves a structure that look like this
> (from top to bottom):
>
> RootLayoutPanel
> DockLayoutPanel
> DockLayoutPanel
> SplitLayoutPanel
>  DockLayoutPanel
> FramedPanel (Sencha)
> VerticalLayoutContainer (Sencha)
> Grid (Sencha)
>
> All of this nesting is done on the part of the widget that auto-expands
> like the center of a DockLayoutPanel.
>
> The problem is that the initial grid doesn't take up all vertical space as
> it should.  If I resize the browser everything corrects itself and it looks
> perfect.  I tried putting a forceLayout call at each of the five top levels
> (separately).  Each failed to correctly setup the initial screen.
>
> The thing mainly not displaying correctly is the grid.  It shows no lines
> unless I resize the display.
>
> I am pretty lost and don't know what else to try.
>
> Thanks.
>
> Blake McBride
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to