
pce_dispatch.pl -- Run XPCE in a separate thread
This module allows one to run XPCE in a separate thread pce. This is
especially nice if xpce is only used to support the SWI-Prolog
development tools because it ensures that the tools remain responsive
while the main thread executes long-running goals.
This module can be deactivated by setting the flag xpce_threaded:
:- set_prolog_flag(xpce_threaded, false).
pce_dispatch(+Options) is det- Create a new thread
pcethat takes care of the XPCE message loop. This predicate has no effect if dispatching is already on another thread than themain. The loop can be ended using pce_end_dispatch/0.
pce_end_dispatch is det- End the XPCE dispatcher loop started with pce_dispatch/1.
pce_call(:Goal) is det- Run Goal in the XPCE thread.