mi32/xmipane.h

Go to the documentation of this file.
00001 /**
00002  * \file xmipane.h <mi32/xmipane.h>
00003  * \brief Definitions for XmiPane widget.
00004  *
00005  * \if NODOC
00006  * $Id: xmipane.h_v 1.10 2005/11/30 15:25:06 mju Exp $
00007  *
00008  * $Log: xmipane.h_v $
00009  * Revision 1.10  2005/11/30 15:25:06  mju
00010  * REmove computeSize as does not work.
00011  *
00012  * Revision 1.9  2005/11/30 14:46:53  mju
00013  * Add xmiPaneComputeSize
00014  *
00015  * Revision 1.8  2004/03/08 15:37:15  mju
00016  * Fix comment for old mgui hdr.
00017  *
00018  * Revision 1.7  2003/09/15 13:49:56  fileserver!dwilliss
00019  * Doxygen
00020  *
00021  * Revision 1.6  2002/02/20 16:01:29  mju
00022  * Add comments for support XtNminHeight/Width constraint resources.
00023  *
00024  * Revision 1.5  2001/12/20 14:37:55  mju
00025  * Change comment about spacing to say not added around border.
00026  *
00027  * Revision 1.4  2001/12/11 17:54:50  mju
00028  * Add orientations for horizontal LtoR and RtoL.
00029  *
00030  * Revision 1.3  2001/12/11 17:17:23  mju
00031  * Change default sizealign to FixedSize.
00032  *
00033  * Revision 1.2  2001/12/11 16:59:36  mju
00034  * Add documentation comments.
00035  *
00036  * Revision 1.1  2001/12/10 21:17:03  mju
00037  * Initial revision
00038  *
00039  * \endif
00040 **/
00041 
00042 #ifndef  INC_MI32_XMIPANE_H
00043 #define  INC_MI32_XMIPANE_H
00044 
00045 #ifndef _XmBulletinBoard_h
00046 #include <Xm/BulletinB.h>
00047 #endif
00048 
00049 extern "C" {
00050 
00051 //!:Associate with "XmiPane widget functions"
00052 //!\addtogroup XmiPane XmiPane Widget Functions
00053 //!@{
00054 
00055 extern WidgetClass xmiPaneWidgetClass;
00056 
00057 //! Add expanding space to pane.
00058 //! Space will be inserted after the most recently added child, or
00059 //! if no children have yet been added, before the first child.
00060 void XmiPaneAddSpaceExpanding (
00061    Widget PaneWidget
00062    );
00063 
00064 //! Add fixed space to pane.
00065 //! Space will be inserted after the most recently added child, or
00066 //! if no children have yet been added, before the first child.
00067 void XmiPaneAddSpaceFixed (
00068    Widget PaneWidget,
00069    int size
00070    );
00071 
00072 //! Create unmanaged XmiPane widget.
00073 //!
00074 //! An XmiPane is a composite container widget which places its children in either a
00075 //! horizontal or vertical "pane".  Children are arranged in the order in which they
00076 //! are added, with optional fixed and expanding space between each child and before
00077 //! the first child.
00078 //!
00079 //! XmiPane inherits behavior from XmBulletinBoard.
00080 //! The class pointer is xmiPaneWidgetClass.
00081 //!
00082 //!
00083 //! The following resources are available for XmiPane:
00084 //!      Name                    Default                          Access
00085 //!         Class                   Type
00086 //!      XmNmarginHeight         0                                CSG
00087 //!         XmCMarginHeight         Dimension                     (Inherited from BulletinBoard)
00088 //!      XmNmarginWidth          0                                CSG
00089 //!         XmCMarginWidth          Dimension                     (Inherited from BulletinBoard)
00090 //!      XtNorientation          XmiPANE_ORIENTATION_HORIZONTAL   CG
00091 //!         XtCOrientation          unsigned char
00092 //!      XmiNspacing             4                                CSG
00093 //!         XmiCSpacing             Dimension
00094 //!      XmiNignoreNonVisible    False                            CSG
00095 //!         XmiCIgnoreNonVisible    Boolean
00096 //!
00097 //!   XtNorientation
00098 //!      Determines whether children are horizontally or vertically.  Possible values are:
00099 //!         XmiPANE_ORIENTATION_HORIZONTAL         Order horizontally based on locale
00100 //!         XmiPANE_ORIENTATION_HORIZONTAL_LTOR    Order horizontally left to right
00101 //!         XmiPANE_ORIENTATION_HORIZONTAL_RTOL    Order horizontally right to left
00102 //!         XmiPANE_ORIENTATION_VERTICAL           Order vertically top to bottom
00103 //!      Values are equal to the corresponding MGUI::LAYOUT_ORIENTATION enum values in <mgui/layout.h>.
00104 //!
00105 //!   XmiNspacing
00106 //!      Determines spacing between children in the pane orientation.  This spacing is not added
00107 //!      between the children and pane edges, use XmNmarginWidth and XmNmarginHeight in that case.
00108 //!
00109 //!   XmiNignoreNonVisible
00110 //!      Determines whether space for nonvisible (unmanaged) children is retained in the layout
00111 //!      or not.  The default of False will retain space, thus retaining all managed child
00112 //!      positions.  Setting this resource to True will cause the Pane to adjust the positions
00113 //!      of remaining visible children to fill the space left by the unmanaged child(ren).
00114 //!
00115 //!
00116 //!   The following constraint resources are available to children of XmiPane:
00117 //!      Name                    Default                          Access
00118 //!         Class                   Type
00119 //!      XmiNsizeAlign           XmiPANE_SIZEALIGN_FixedSize      CG
00120 //!         XmiCSizeAlign           unsigned short
00121 //!      XtNminHeight            [none]                           CSG
00122 //!         XtCMinHeight            Dimension
00123 //!      XtNminWidth             [none]                           CSG
00124 //!         XtCMinWidth             Dimension
00125 //!
00126 //!   XmiNsizeAlign
00127 //!      Determines how a child is sized and aligned with other children in the parent XmiPane.
00128 //!      The values for this resource may be bitwise-or'd (|) together.  In addition, these values
00129 //!      exactly correspond to the MGUI::LAYOUT_SIZEALIGN enum values defined in <mgui/layout.h>
00130 //!
00131 //!      XmiPANE_SIZEALIGN_Expand            Expand both width and height to fill space
00132 //!      XmiPANE_SIZEALIGN_FixedWidth        Width fixed, height can change
00133 //!      XmiPANE_SIZEALIGN_FixedHeight       Height fixed, width can change
00134 //!      XmiPANE_SIZEALIGN_FixedSize         Both horizontal and vertical size fixed
00135 //!      XmiPANE_SIZEALIGN_AlignLeft         Align with left edge of available space
00136 //!      XmiPANE_SIZEALIGN_AlignRight        Align with right edge of available space
00137 //!      XmiPANE_SIZEALIGN_AlignTop          Align with top edge of available space
00138 //!      XmiPANE_SIZEALIGN_AlignBottom       Align with bottom edge of available space
00139 //!      XmiPANE_SIZEALIGN_CenterHorz        Center horizontally in available space
00140 //!      XmiPANE_SIZEALIGN_CenterVert        Center vertically in available space
00141 //!      XmiPANE_SIZEALIGN_Center            Center both horizontal and vertically
00142 //!
00143 //!   XtNminHeight
00144 //!      Minimum height of child in pixels.  If not specified will default to the initial child height.
00145 //!
00146 //!   XtNminWidth
00147 //!      Minimum width of child in pixels.  If not specified will default to the initial child width.
00148 //!      
00149 Widget XmiPaneCreate (
00150    Widget parent,
00151    char *name,
00152    ArgList arglist,
00153    Cardinal argcount
00154    );
00155 
00156 //! Create Dialog and XmiPane widget.
00157 Widget XmiPaneCreateDialog (
00158    Widget parent,
00159    char *name,
00160    ArgList arglist,
00161    Cardinal argcount
00162    );
00163 
00164 //! Determine if widget is an XmiPane or subclass thereof.
00165 inline Boolean XmiIsPane (
00166    Widget w
00167    ) {
00168    return (XtIsSubclass(w, xmiPaneWidgetClass));
00169    }
00170 
00171 //! Pane child placement orientation.
00172 //! These values must remain equal to the corresponsing MGUI::LAYOUT_ORIENTATION values in <mgui/layout.h>
00173 #define  XmiPANE_ORIENTATION_HORIZONTAL      0           //!< Horizontal layout based on locale
00174 #define  XmiPANE_ORIENTATION_VERTICAL        1           //!< Vertical layout top to bottom
00175 #define  XmiPANE_ORIENTATION_HORIZONTAL_LTOR 2           //!< Horizontal layout left to right
00176 #define  XmiPANE_ORIENTATION_HORIZONTAL_RTOL 3           //!< Horizontal layout right to left
00177 
00178 //! Child sizing/alignment constraint values, can be |'d together.
00179 //! These values must remain equal to the corresponding MGUI::LAYOUT_SIZEALIGN values in <mgui/layout.h>
00180 #define  XmiPANE_SIZEALIGN_Expand            0x0000      //!< Expand both width and height to fill space
00181 #define  XmiPANE_SIZEALIGN_FixedWidth        0x0001      //!< Width fixed, height can change
00182 //!#define  XmiPANE_SIZEALIGN_RelativeHorz      0x0002
00183 #define  XmiPANE_SIZEALIGN_FixedHeight       0x0004      //!< Height fixed, width can change
00184 //!#define  XmiPANE_SIZEALIGN_RelativeVert      0x0008
00185 #define  XmiPANE_SIZEALIGN_FixedSize         0x0005      //!< Both horizontal and vertical size fixed
00186 #define  XmiPANE_SIZEALIGN_AlignLeft         0x0010      //!< Align with left edge of available space
00187 #define  XmiPANE_SIZEALIGN_AlignRight        0x0020      //!< Align with right edge of available space
00188 #define  XmiPANE_SIZEALIGN_AlignTop          0x0040      //!< Align with top edge of available space
00189 #define  XmiPANE_SIZEALIGN_AlignBottom       0x0080      //!< Align with bottom edge of available space
00190 #define  XmiPANE_SIZEALIGN_CenterHorz        0x0030      //!< Center horizontally in available space
00191 #define  XmiPANE_SIZEALIGN_CenterVert        0x00C0      //!< Center vertically in available space
00192 #define  XmiPANE_SIZEALIGN_Center            0x00F0      //!< Center both horizontal and vertically
00193 
00194 
00195 #define  XmiNspacing             "spacing"
00196 #define  XmiCSpacing             "Spacing"
00197 #define  XmiNignoreNonVisible    "ignoreNonVisible"
00198 #define  XmiCIgnoreNonVisible    "IgnoreNonVisible"
00199 #define  XmiNsizeAlign           "sizeAlign"
00200 #define  XmiCSizeAlign           "SizeAlign"
00201 
00202 //!@}
00203 
00204 }  /* Close scope of 'extern "C"' declaration which encloses file. */
00205 
00206 #endif   //!< INC_MI32_XMIPANE_H

Generated on Thu Apr 26 04:45:29 2007 for TNTsdk by  doxygen 1.5.2