hpux man page for xtnumber

Query: xtnumber

OS: hpux

Section: 1

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

XtNumber()																XtNumber()

Name
  XtNumber - determine the number of elements in a fixed-size array.

Synopsis
  Cardinal XtNumber(array)

Inputs
  array     Specifies a fixed-size array of arbitrary type.

Returns
  The number of elements in array.

Description
  XtNumber()  returns  the  number  of	elements in the specified argument list, resource list, or other fixed-size array.  It works only for
  objects which have been statically initialized or declared with a fixed number of elements, i.e., arrays whose total size is known at  com-
  pile time.

Usage
  You should use XtNumber() whenever you are passing a static array to a function or storing an static array in a structure that also expects
  the number of elements in the array.	This way, if you change the number of element in the array, the correct number of elements will auto-
  matically be compiled in.

Background
  XtNumber() is a macro defined as follows:

     #define XtNumber(arr)  ((Cardinal) (sizeof(arr) / sizeof(arr[0])))

See Also
  XtOffset(1), XtOffsetOf(1), XtSetArg(1).

Xt - Argument Lists															XtNumber()
Related Man Pages
xtnumber(3xt) - osf1
xtnumber(3) - debian
xtoffset(3) - centos
xtoffset(3) - suse
xtoffsetof(3) - suse
Similar Topics in the Unix Linux Community
Compilation error : Please help
Need help in resolving Compilation error
how to change the default background color for x windows
Xaw3d asciiTextWidget: how to scroll right without scrollbar
Mathematical Loop