How to draw line between two TreeView in GEF [message #153476] |
Sun, 10 October 2004 12:34 |
Eclipse User |
|
|
|
Originally posted by: lin_tower.hotmail.com
Hi all,
I want to draw lines between two TreeView, like the attached image
does.The lines have their own properties, so I use GEF to implement it. My
plan is to do like this:
----------------------
| | | |
| | | |
| Tree | GEF | Tree |
| | | |
| | | |
----------------------
but I don't know if we could connect two TreeItem. How could I implement
it?
And there is org.eclipse.gef.ui.parts.TreeViewer in GEF. I wonder what
that for,can I use that to build a tree?
|
|
|
Re: How to draw line between two TreeView in GEF [message #153602 is a reply to message #153476] |
Mon, 11 October 2004 15:25 |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
I don't think you can:
1) Paint on top of an SWT tree reliably.
2) Obtain the bounding box of a TreeItem.
You may be able to calculate the Y-location of a treeitem, and paint
everything completely outside the tree. You will still have to track
expand/collapse of the treeitem, and scrolling of the tree. This may not be
possible either.
The alternative is to render your own thing which looks like a tree, using
GEF and Figures perhaps.
"lee" <lin_tower@hotmail.com> wrote in message
news:ckb9qk$dq9$1@eclipse.org...
> Hi all,
> I want to draw lines between two TreeView, like the attached image
> does.The lines have their own properties, so I use GEF to implement it. My
> plan is to do like this:
> ----------------------
> | | | |
> | | | |
> | Tree | GEF | Tree |
> | | | |
> | | | |
> ----------------------
> but I don't know if we could connect two TreeItem. How could I
implement
> it?
> And there is org.eclipse.gef.ui.parts.TreeViewer in GEF. I wonder what
> that for,can I use that to build a tree?
>
>
>
>
>
|
|
|
Re: How to draw line between two TreeView in GEF [message #153707 is a reply to message #153602] |
Tue, 12 October 2004 05:15 |
Eclipse User |
|
|
|
Originally posted by: lin_tower.hotmail.com
Thanks for advice. It seems the only way is to build the TreeView in GEF,
then how to use org.eclipse.gef.ui.parts.TreeViewer to build a TreeView?
Is there any example or code snippet shows how to that?
Thanks.
Best regards,
lee
Randy Hudson wrote:
> I don't think you can:
> 1) Paint on top of an SWT tree reliably.
> 2) Obtain the bounding box of a TreeItem.
> You may be able to calculate the Y-location of a treeitem, and paint
> everything completely outside the tree. You will still have to track
> expand/collapse of the treeitem, and scrolling of the tree. This may not be
> possible either.
> The alternative is to render your own thing which looks like a tree, using
> GEF and Figures perhaps.
> "lee" <lin_tower@hotmail.com> wrote in message
> news:ckb9qk$dq9$1@eclipse.org...
> > Hi all,
> > I want to draw lines between two TreeView, like the attached image
> > does.The lines have their own properties, so I use GEF to implement it. My
> > plan is to do like this:
> > ----------------------
> > | | | |
> > | | | |
> > | Tree | GEF | Tree |
> > | | | |
> > | | | |
> > ----------------------
> > but I don't know if we could connect two TreeItem. How could I
> implement
> > it?
> > And there is org.eclipse.gef.ui.parts.TreeViewer in GEF. I wonder what
> > that for,can I use that to build a tree?
> >
> >
> >
> >
> >
|
|
|
Re: How to draw line between two TreeView in GEF [message #153768 is a reply to message #153707] |
Tue, 12 October 2004 15:30 |
Eclipse User |
|
|
|
Originally posted by: none.us.ibm.com
TreeViewer is for native SWT Tree control. That won't help you with your
problem.
"lee" <lin_tower@hotmail.com> wrote in message
news:ckfpa0$gjc$1@eclipse.org...
> Thanks for advice. It seems the only way is to build the TreeView in GEF,
> then how to use org.eclipse.gef.ui.parts.TreeViewer to build a TreeView?
> Is there any example or code snippet shows how to that?
>
> Thanks.
>
> Best regards,
> lee
>
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03450 seconds