Re: XForms: Detaching a form from a tabfolder

Steve Lamont (spl@szechuan.ucsd.edu)
Wed, 6 Oct 99 06:17:50 PDT

# To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> Does anyone know how I can remove a form from a tabfolder and then
> display it in a window of its own? I would have guessed that
> something like this would do it:
>
> {
> FL_OBJECT *tabfolder = ...;
> FL_FORM *form = fl_get_active_folder (tabfolder);
>
> fl_delete_folder (tabfolder, form);
> fl_show_form (form, FL_PLACE_FREE, FL_TRANSIENT, "XXX");
> }

I've never tried to do this but I expect you have to create a new
instance of the form and show it in the standard manner. This, of
course, means that you must copy all of the state information from the
TabFolder version of the form into the free standing version.

The way that the TabFolder is implemented is that the child form
Windows are created and reparented to a Canvas object. Reparenting
the Window back to the window manager could probably be done but I
suspect that it's messy and fraught with pitfalls. Unless I miss my
guess, it's easier just to delete one form and create a new one.

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