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

FreeBSD Manual Pages

  
 
  

home | help
XtAllocateGC(3) 		  XT FUNCTIONS			 XtAllocateGC(3)

NAME
     XtAllocateGC - obtain a shareable GC with modifiable fields

SYNTAX
     #include <X11/Intrinsic.h>

     GC  XtAllocateGC(Widget  w,  Cardinal depth, XtGCMask value_mask, XGCValues
	    *values, XtGCMask dynamic_mask, XtGCMask unused_mask);

ARGUMENTS
     values    Specifies the actual values for this GC.

     value_maskSpecifies which fields of the values are specified.

     w	       Specifies the widget.

     depth     Specifies the depth for which the returned GC is valid, or 0.

     dynamic_mask
	       Specifies the fields of the GC  that  will  be  modified  by  the
	       caller.

     unused_mask
	       Specifies  the  fields  of  the GC that will not be needed by the
	       caller.

DESCRIPTION
     The XtAllocateGC function returns a shareable GC that may	be  modified  by
     the  client.   The  screen  field of the specified widget or of the nearest
     widget ancestor of the specified object and the  specified  depth	argument
     supply  the  root	and drawable depths for which the GC is to be valid.  If
     depth is zero the depth is taken from the depth field of the specified wid-
     get or of the nearest widget ancestor of the specified object.

     The value_mask argument specifies the fields of the GC that  will	be  ini-
     tialized  with  the  respective  members  of the values structure.  The dy-
     namic_mask argument specifies fields that the caller intends to modify dur-
     ing program execution.  The caller must ensure that  the  corresponding  GC
     field  is	set prior to each use of the GC. The unused_mask argument speci-
     fies fields of the GC that are of no interest to the  caller.   The  caller
     may  make	no assumptions about the contents of any fields specified in un-
     used_mask. The caller may assume that at all times all fields not specified
     in either dynamic_mask or unused_mask have their default value if not spec-
     ified in value_mask or the value specified by values.  If a field is speci-
     fied in both value_mask and dynamic_mask, the effect is as if it were spec-
     ified only in dynamic_mask and then immediately set to the value in values.
     If a field is set in unused_mask and  also  in  either  value_mask  or  dy-
     namic_mask, the specification in unused_mask is ignored.

     XtAllocateGC  tries to minimize the number of unique GCs created by compar-
     ing the arguments with those of previous calls and returning an existing GC
     when there are no conflicts.  XtAllocateGC may modify and return an  exist-
     ing GC if it was allocated with a nonzero unused_mask.

SEE ALSO
     XtGetGC
     X Toolkit Intrinsics - C Language Interface
     Xlib - C Language X Interface

X Version 11			   libXt 1.3.1			 XtAllocateGC(3)

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

home | help