Hi!

I guess the point is that you used a FlowPanel which does not stretch
its children. I found out that this is also true for AbsolutePanel.

Thanks!

BTW: I wonder why you use this construct:

 int parentH = dock.getWidgetContainerElement(this).getOffsetHeight();

Why not simply call:

doc.getParent ().gettOffsetHeight(); ?

The latter code would also be usable for parents that are no
DockLayoutgPanel. Is there a special reason?

Magnus


On 12 Jun., 15:11, "Alejandro D. Garin" <aga...@gmail.com> wrote:
> Hi
>
> Try this: (only tested on mac FF and Safari)
>
> http://www.puntosoft.com.ar/gwt/layoutChess/FormTable.java
>
> On Sat, Jun 12, 2010 at 12:23 AM, Magnus <alpineblas...@googlemail.com>wrote:
>
> > Hi Alejandro,
>
> > I think you are replying to a post that I cancelled. I did so, because
> > I managed to reproduce this behavior with a minimalistic piece of code
> > so that it was clear that it must be a general issue. I found that
> > here must be a problem in the GWT version that is not fixed yet:
> >http://code.google.com/p/google-web-toolkit/issues/detail?id=4532
>
> > But let me come back to your code for centering the chess board: The
> > main prerequisite is that you set (and therefore know) the pixel size
> > of the inner box to 400,400.
>
> > However, doing the same with a form was not possible for me since I am
> > building on top of your code template. The reason is that I don't know
> > the size of my form. I put all the widgets together in a panel (I
> > tried every type) and add this panel to my DockLayoutPanel. Then it's
> > immediately stretched, so that I cannot retrieve its "natural" size.
> > But exactly this size is needed to do the centering as you did in your
> > code.
>
> > How would you do this? Can you help me again?
>
> > Thank you
> > Magnus

-- 
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-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to