Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Preview RootEditPart before displaying in main view
Preview RootEditPart before displaying in main view [message #189380] Tue, 26 July 2005 21:20 Go to next message
Eclipse UserFriend
Originally posted by: kblanchard85.hotmail.com

I am trying to find a way to display a rooteditpart in a different view,
but even when I try to set the contents in the graphical viewer and get
the figure out, I just get a white image. Is there anyway to have create
a graphical viewer, set the contents, and have them be painted, right
away, to a canvas but NOT be displayed? Thanks in advance!

-Kyle
Re: Preview RootEditPart before displaying in main view [message #189495 is a reply to message #189380] Wed, 27 July 2005 15:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.unknown.com

"Kyle Blanchard" <kblanchard85@hotmail.com> wrote in message
news:dc69dq$7h3$1@news.eclipse.org...
> I am trying to find a way to display a rooteditpart in a different view,
> but even when I try to set the contents in the graphical viewer and get
> the figure out, I just get a white image. Is there anyway to have create

Do you want to just display what the figures look like? You can do that via
Thumbnail and ScrollableThumbnail. If you want to do it yourself, just
create a Graphics wrapper for a GC that paints on an Image and invoke the
root figure's paint method with that as the argument.

> a graphical viewer, set the contents, and have them be painted, right
> away, to a canvas but NOT be displayed? Thanks in advance!
>
> -Kyle
Re: Preview RootEditPart before displaying in main view [message #189565 is a reply to message #189495] Wed, 27 July 2005 18:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: kblanchard85.hotmail.com

I guess what I am trying to say is I want the figure to be painted to
the main canvas once I call setcontents. I have multiple editparts (that
will be displayed independently of each other in the main view) that I
want to preview. However, in initializeGraphicalViewer in the editor,
the contents of the editpart are not getting painted until later. I want
to know where so I can retreive the updated figure after it is painted.

Pratik Shah wrote:
> "Kyle Blanchard" <kblanchard85@hotmail.com> wrote in message
> news:dc69dq$7h3$1@news.eclipse.org...
>
>>I am trying to find a way to display a rooteditpart in a different view,
>>but even when I try to set the contents in the graphical viewer and get
>>the figure out, I just get a white image. Is there anyway to have create
>
>
> Do you want to just display what the figures look like? You can do that via
> Thumbnail and ScrollableThumbnail. If you want to do it yourself, just
> create a Graphics wrapper for a GC that paints on an Image and invoke the
> root figure's paint method with that as the argument.
>
>
>>a graphical viewer, set the contents, and have them be painted, right
>>away, to a canvas but NOT be displayed? Thanks in advance!
>>
>>-Kyle
>
>
>
Re: Preview RootEditPart before displaying in main view [message #189614 is a reply to message #189565] Wed, 27 July 2005 21:51 Go to previous message
Eclipse UserFriend
Originally posted by: kblanchard85.hotmail.com

I've got it. After setting the contents, you have to get the control
from the graphical viewer and call redraw, and update the display of the
editor site's shell.

Kyle Blanchard wrote:
> I guess what I am trying to say is I want the figure to be painted to
> the main canvas once I call setcontents. I have multiple editparts (that
> will be displayed independently of each other in the main view) that I
> want to preview. However, in initializeGraphicalViewer in the editor,
> the contents of the editpart are not getting painted until later. I want
> to know where so I can retreive the updated figure after it is painted.
>
> Pratik Shah wrote:
>
>> "Kyle Blanchard" <kblanchard85@hotmail.com> wrote in message
>> news:dc69dq$7h3$1@news.eclipse.org...
>>
>>> I am trying to find a way to display a rooteditpart in a different view,
>>> but even when I try to set the contents in the graphical viewer and get
>>> the figure out, I just get a white image. Is there anyway to have create
>>
>>
>>
>> Do you want to just display what the figures look like? You can do
>> that via
>> Thumbnail and ScrollableThumbnail. If you want to do it yourself, just
>> create a Graphics wrapper for a GC that paints on an Image and invoke the
>> root figure's paint method with that as the argument.
>>
>>
>>> a graphical viewer, set the contents, and have them be painted, right
>>> away, to a canvas but NOT be displayed? Thanks in advance!
>>>
>>> -Kyle
>>
>>
>>
>>
Previous Topic:Figure with Button, or manual Command execution
Next Topic:size of graphical editor
Goto Forum:
  


Current Time: Thu Dec 26 21:55:48 GMT 2024

Powered by FUDForum. Page generated in 0.03629 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top