Lisp HUG Maillist Archive

Modifying CAPI elements in multi-threaded program

Hi!

The CAPI User Guide says that "a displayed CAPI element should only be
modified in its own thread." I'm currently writing my first "real"
CAPI application (so this may be a dumb question) and I have a
situation where I intend to start a (background) thread by pressing a
push button. I want this background thread to be able to modify a
display-pane or something similar so there's always a line somewhere
in my GUI telling me the current status of the background thread.

How am I supposed to do that without violating the rule cited above?

Thanks in advance,
Edi.


Re: Modifying CAPI elements in multi-threaded program

Edi Weitz <edi@agharta.de> writes:

> Hi!
> 
> The CAPI User Guide says that "a displayed CAPI element should only be
> modified in its own thread." I'm currently writing my first "real"
> CAPI application (so this may be a dumb question) and I have a
> situation where I intend to start a (background) thread by pressing a
> push button. I want this background thread to be able to modify a
> display-pane or something similar so there's always a line somewhere
> in my GUI telling me the current status of the background thread.
> 
> How am I supposed to do that without violating the rule cited above?
> 
> Thanks in advance,
> Edi.

Uh, sorry, it was late yesterday. I should have heard about the
cookbook before... :)

  <http://cl-cookbook.sourceforge.net/process.html#capi>

Cheers,
Edi.


Updated at: 2020-12-10 09:00 UTC