Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » paintChildren and IProgressMonitor updates
paintChildren and IProgressMonitor updates [message #210733] Sun, 05 March 2006 12:01 Go to next message
Eclipse UserFriend
Originally posted by: kvdijken.tiscali.nl

Hello,

I want to update the progressMonitor (message and work) in the statusbar
during a call to Figure.paintChildren(). I cannot get it to work however.
Nothing is displayed.

Is it possible? Did anyone have any luck doing the same?

Koen
Re: paintChildren and IProgressMonitor updates [message #210835 is a reply to message #210733] Mon, 06 March 2006 15:03 Go to previous messageGo to next message
Steven R. Shaw is currently offline Steven R. ShawFriend
Messages: 128
Registered: July 2009
Senior Member
Intuitively this seems like an improper place to be updating progress.
Usually this is done in context to command execution.

Regarding your specific problem, since paintChildren is being executed on
the UI thread, updating the statusbar is probably doing a Display.asyncExec
to update meaning it will not spawn execution until the current execution is
finished before exeucting.

-Steve

"Koen van Dijken" <kvdijken@tiscali.nl> wrote in message
news:duejvf$nde$1@eclipse.org...
> Hello,
>
> I want to update the progressMonitor (message and work) in the statusbar
> during a call to Figure.paintChildren(). I cannot get it to work however.
> Nothing is displayed.
>
> Is it possible? Did anyone have any luck doing the same?
>
> Koen
>
>
Re: paintChildren and IProgressMonitor updates [message #210866 is a reply to message #210835] Mon, 06 March 2006 15:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: kvdijken.tiscali.nl

Does that imply that all these processes which do use a progressbar on the
statusline are working as background jobs? Or are are they doing
Display.getCurrent().readAndDispatch() at regular intervals? I tried
readAndDispatch in the paintChildren() method, but that results in rather
messy displays...

Koen



"Steven Shaw" <steveshaw@ca.ibm.com> wrote in message
news:duhiq9$s7t$1@eclipse.org...
> Intuitively this seems like an improper place to be updating progress.
> Usually this is done in context to command execution.
>
> Regarding your specific problem, since paintChildren is being executed on
> the UI thread, updating the statusbar is probably doing a
> Display.asyncExec
> to update meaning it will not spawn execution until the current execution
> is
> finished before exeucting.
>
> -Steve
>
> "Koen van Dijken" <kvdijken@tiscali.nl> wrote in message
> news:duejvf$nde$1@eclipse.org...
>> Hello,
>>
>> I want to update the progressMonitor (message and work) in the statusbar
>> during a call to Figure.paintChildren(). I cannot get it to work however.
>> Nothing is displayed.
>>
>> Is it possible? Did anyone have any luck doing the same?
>>
>> Koen
>>
>>
>
>
Re: paintChildren and IProgressMonitor updates [message #211012 is a reply to message #210733] Tue, 07 March 2006 17:47 Go to previous message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

If your painting is so slow (and there are valid cases I'm sure), you should
be rendering to an Image, and then just painting that Image. Otherwise,
closing a dialog box or context menu will take too long.

You could then create a job that updates the cached image.

"Koen van Dijken" <kvdijken@tiscali.nl> wrote in message
news:duejvf$nde$1@eclipse.org...
> Hello,
>
> I want to update the progressMonitor (message and work) in the statusbar
> during a call to Figure.paintChildren(). I cannot get it to work however.
> Nothing is displayed.
>
> Is it possible? Did anyone have any luck doing the same?
>
> Koen
>
Previous Topic:How to add Subpalette entries
Next Topic:Grid line Pattern
Goto Forum:
  


Current Time: Thu Apr 25 09:21:16 GMT 2024

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

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

Back to the top