I have a Composite which I will place in an Absolute Panel, I want to be able to specify the location coordinates of the composite and place it at that location in the absolute panel.
Also, at run time, sometime I will have to change the location coordinates of the Composite and move it.
I could have use a grid or other panel but while moving the composit, I want to place a move animation, that’s why I’m using an absolute panel.
How to specify the coordinates of the composite before placing it in the absolute panel?
the composite:
public class SlotView extends Composite
{
...
}
AbsolutePanel.setWidgetPosition()will change the location of a Widget displayed inside of anAbsolutePanel. This is limited only to using pixel-based offsets.A more robust solution is to use a
LayoutPanel, which supports the use of font- or box-relative positions.LayoutPanelalso has support for animating transitions.