Re: XForms: Forking Behaviour

Frank Stefani (EAD-Frank.Stefani@t-online.de)
Wed, 21 May 1997 09:52:49 +0200

To subscribers of the xforms list from EAD-Frank.Stefani@t-online.de (Frank Stefani) :

Steve Lamont wrote:
>
> To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :
>
> > Is there a way to close this file descriptor in a child process? The
> > child processes I'm starting don't need to have any access to graphics at
> > all, but *do* need to be started after the fl_initialize routine is
> > called.
>
> I guess first off I'd have to ask myself if this *is* absolutely
> necessary and redesign the code if it was not.

Hmmm, I don't think this statement helps very much in this case. Steven
Ness wrote already, that he "does need" this sequence order of function
calls.

I discovered a similar behavior with browsers. Especially, browsers are
in some situations (not to be explained here, but I can reproduce the
behaviour) only drawn partially. In my case, I had only the window
manager
decoration of the browser drawn. Then, like Steven, I could "use" the
browser
like usual, but nothing was visible. The browser looked like a glass
window,
well, a real physical window. I saw the fvwm decoration and the
background
within it, but no browser items.

The workaround for this is:

fd_mybrowser_frm= create_form_mybrowser_frm();

is called somwhere in 'main()', before 'fl_do_forms()'. Then, whenever I
hide the browser, I destroyed it (well, it *is* destroyed) and I
explicitly
freed the memory. For the next 'show' to be performed, I rebuilt the
browser
again with

fd_mybrowser_frm= create_form_mybrowser_frm();

whereever needed. This works fine for me. My application makes heavy use
of
'fork()' with IPC through PIPE's and I/O callbacks. I'm using Linux
2.0.25
and xforms 0.86 fix 1.

BTW: I also discovered this (partially drawing) behaviour since using
0.86,
in 0.84 this problem didn't arise. So I assume it's not IRIX specific.

Hope this helps.

Frank.

-- 
---------------------------------------------------------------
     _/_/_/_/     _/_/     _/_/_/    EAD-Systeme GmbH
    _/          _/  _/    _/    _/   Nachfeldstr. 4
   _/_/_/     _/    _/   _/     _/   D-82490 Farchant, Germany
  _/        _/_/_/_/_/  _/     _/    Phone: +49 8821 9623-0
 _/_/_/_/ _/        _/ _/_/_/_/      Fax: +49 8821 9623-20
---------------------------------------------------------------
Email: EAD-Frank.Stefani@t-online.de
---------------------------------------------------------------

_________________________________________________ To unsubscribe, send the message "unsubscribe" to xforms-request@bob.usuf2.usuhs.mil or see http://bob.usuf2.usuhs.mil/mailserv/xforms.html Xforms Home Page: http://bragg.phys.uwm.edu/xforms List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/