|
|
Re: Draw2d layout, fixed positions [message #229631 is a reply to message #229133] |
Mon, 22 January 2007 16:35 |
Nhu Le Messages: 47 Registered: July 2009 |
Member |
|
|
Knowing the position of figures does not give you much unless you know
it is with respect to what. Is it relative to the screen, the viewport,
the scrolledpane, or some other components around it?. The position of
a figure does not change unless you make it.
If you want to make a figure stationary visually in the view when you
scroll, you have to make it relative to the viewport (meaning its
position must change to compensate for the change in the viewport with
respect to the scrolledpane).
Nhu
Tomas Studva wrote:
> Hi everybody,
> I know positions of figures and I don't want these positions to be changed.
>
> How can I say this figure has this size and should be placed at this position?
>
> Is it possible to do it without layout manager, just saying:
> figure.setLocation()
> figure.setSize() - do I need to set also preferred size, what is the difference?
>
> Thanks for help. I think the main problem with Draw2d is poor documentation, I haven't find anything useful on this topic.
>
> Tomas Studva
|
|
|
Re: Draw2d layout, fixed positions [message #229638 is a reply to message #229133] |
Mon, 22 January 2007 20:44 |
Eclipse User |
|
|
|
Originally posted by: mn.puakma.net
Howdy, try to set XYLayout layout on the parent figure, and then call
XYLayout.setConstraint(childFigure, new Rectangle(...))
Martin
Tomas Studva wrote:
> Hi everybody,
> I know positions of figures and I don't want these positions to be changed.
>
> How can I say this figure has this size and should be placed at this position?
>
> Is it possible to do it without layout manager, just saying:
> figure.setLocation()
> figure.setSize() - do I need to set also preferred size, what is the difference?
>
> Thanks for help. I think the main problem with Draw2d is poor documentation, I haven't find anything useful on this topic.
>
> Tomas Studva
|
|
|
Powered by
FUDForum. Page generated in 0.03145 seconds