Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
XmtCreateChild(3)	    Library Functions Manual	       XmtCreateChild(3)

NAME
     XmtCreateChild(), XmtCreateQueryChild(), XmtCreateQueryListChild() - create
     a named child and all of its descendants.

SYNOPSIS
     Widget XmtCreateChild(Widget parent, String name)

     Widget XmtCreateQueryChild(Widget parent, String name,
		    { String child_name, Widget *child_address, }
		    NULL)

     Widget XmtCreateQueryListChild(Widget parent, XmtWidgetList * names,
		    Cardinal num_names)

     typedef struct {
		    XrmQuark nameq;
		    Widget *widgetp;
     } XmtWidgetList;

ARGUMENTS
     INPUTS

	  parent The widget that is to have a named child created.

	  name	 The name of the child to be created.

	  child_name
		 The name of a widget to be returned. May be repeated any number
		 of times in a NULL-terminated variable-length argument list.

	  names  An array containing num_names entries.

	  num_names
		 The number of entries in the namesP lilst.

     OUTPUTS

	  child_address
		 The  address  at which the widget specified by child_name is to
		 be stored. May be repeated any number of times in a NULL-termi-
		 nated variable length argument list.

     RETURNS

	  The newly created child of parent.

DESCRIPTION
     XmtCreateChild(), XmtCreateQueryChild(), and XmtCreateQueryListChild()  are
     similar  to  XmtCreateChildren(),	XmtCreateQueryChildren()  and XmtCreate-
     QueryListChildren(). While the latter functions read  the	xmtChildren  re-
     source  of  a widget and create all of its children, these functions create
     only a single child of the parent widget. The name of this child is  speci-
     fied  by  name, and its type is determined by reading its xmtType resource,
     which must specify a registered widget type or template,  as  described  in
     Chapter 11, Automatic Widget Creation.

     Once  the	functions  have  created  this	first named child, they read the
     child's xmtChildren resource, and proceed to create all of its  descendants
     just  as  the  XmtCreateChildren() family of functions do. Once all descen-
     dants have been created, these functions return the original child widget.

     Like XmtCreateQueryChildren(), XmtCreateQueryChild() can return the widgets
     it creates in the child_address arguments in its NULL-terminated  variable-
     length argument list.

     Also  like  XmtCreateQueryListChildren(), XmtCreateQueryListChild() can re-
     turn the widgets it creates via the names array  argument.  Each  entry  in
     this  array  has  two  values: a XrmQuark nameq and a Widget * widgetp. The
     nameq must be initialized to the Quark corresponding to the  widget's  name
     (typically by calling XrmQuarkToString); the widgetp must be initialized to
     point  to	a Widget variable. The address pointed to by widgetp will be set
     to the address of the last widget created with the given name, or	NULL  if
     no such widget was created.

USAGE
     These  functions are useful when you want to defer creation of some subtree
     of your widget hierarchy. XmtBuildDialog() and XmtBuildToplevel() are  also
     useful for this purpose.

SEE ALSO
     Chapter 11, Automatic Widget Creation,
     XmtBuild[Query]Application(), XmtBuild[Query]Dialog(),
     XmtBuild[Query]Toplevel(), XmtCreate[Query]Children(),
     XmtCreateQueryListChildren().

Xmt				   Motif Tools		       XmtCreateChild(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=XmtCreateChild&sektion=3&manpath=FreeBSD+Ports+15.1.quarterly>

home | help