Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:14:24

0001 /***********************************************************
0002 
0003 Copyright 1987, 1988, 1994, 1998  The Open Group
0004 
0005 Permission to use, copy, modify, distribute, and sell this software and its
0006 documentation for any purpose is hereby granted without fee, provided that
0007 the above copyright notice appear in all copies and that both that
0008 copyright notice and this permission notice appear in supporting
0009 documentation.
0010 
0011 The above copyright notice and this permission notice shall be included in
0012 all copies or substantial portions of the Software.
0013 
0014 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
0015 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
0016 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
0017 OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
0018 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
0019 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
0020 
0021 Except as contained in this notice, the name of The Open Group shall not be
0022 used in advertising or otherwise to promote the sale, use or other dealings
0023 in this Software without prior written authorization from The Open Group.
0024 
0025 
0026 Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts.
0027 
0028                         All Rights Reserved
0029 
0030 Permission to use, copy, modify, and distribute this software and its
0031 documentation for any purpose and without fee is hereby granted,
0032 provided that the above copyright notice appear in all copies and that
0033 both that copyright notice and this permission notice appear in
0034 supporting documentation, and that the name of Digital not be
0035 used in advertising or publicity pertaining to distribution of the
0036 software without specific, written prior permission.
0037 
0038 DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
0039 ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
0040 DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
0041 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
0042 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
0043 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
0044 SOFTWARE.
0045 
0046 ******************************************************************/
0047 
0048 /* Form widget private definitions */
0049 
0050 #ifndef _XawFormP_h
0051 #define _XawFormP_h
0052 
0053 #include <X11/Xfuncproto.h>
0054 
0055 #include <X11/Xaw/Form.h>
0056 #include <X11/Xaw/XawInit.h>
0057 
0058 _XFUNCPROTOBEGIN
0059 
0060 #define XtREdgeType "EdgeType"
0061 
0062 typedef enum {
0063     LayoutPending,
0064     LayoutInProgress,
0065     LayoutDone
0066 } LayoutState;
0067 
0068 #define XtInheritLayout                         \
0069 ((Boolean (*)(FormWidget, unsigned int, unsigned int, Bool))_XtInherit)
0070 
0071 typedef struct {
0072     Boolean(*layout)(FormWidget, unsigned int, unsigned int, Bool);
0073 #ifndef OLDXAW
0074     XtPointer extension;
0075 #endif
0076 } FormClassPart;
0077 
0078 typedef struct _FormClassRec {
0079     CoreClassPart   core_class;
0080     CompositeClassPart  composite_class;
0081     ConstraintClassPart constraint_class;
0082     FormClassPart   form_class;
0083 } FormClassRec;
0084 
0085 extern FormClassRec formClassRec;
0086 
0087 typedef struct _FormPart {
0088     /* resources */
0089     int     default_spacing;    /* default distance between children */
0090 
0091     /* private */
0092     Dimension   old_width, old_height; /* reference value for *_virtual  */
0093     int     no_refigure;        /* no re-layout while > 0        */
0094     Boolean needs_relayout;     /* next time no_refigure == 0    */
0095     Boolean resize_in_layout;   /* should layout() do geom request?  */
0096     Dimension   preferred_width, preferred_height; /* cached from layout */
0097     Boolean resize_is_no_op;    /* Causes resize to take not action  */
0098 #ifndef OLDXAW
0099     XawDisplayList *display_list;
0100     XtPointer pad[4];   /* for future use and keep binary compatibility */
0101 #endif
0102 } FormPart;
0103 
0104 typedef struct _FormRec {
0105     CorePart        core;
0106     CompositePart   composite;
0107     ConstraintPart  constraint;
0108     FormPart        form;
0109 } FormRec;
0110 
0111 typedef struct _FormConstraintsPart {
0112     /* resources */
0113     XtEdgeType top, bottom, left, right;/* where to drag edge on resize */
0114     int     dx;     /* desired horiz offset         */
0115     int     dy;     /* desired vertical offset      */
0116     Widget  horiz_base; /* measure dx from here if non-null */
0117     Widget  vert_base;  /* measure dy from here if non-null */
0118     Boolean allow_resize;   /* True if child may request resize */
0119 
0120     /* private */
0121     short   virtual_width, virtual_height;
0122     Position    new_x, new_y;
0123     LayoutState layout_state;   /* temporary layout state       */
0124     Boolean deferred_resize;/* was resized while no_refigure is set */
0125 #ifndef OLDXAW
0126     short   virtual_x, virtual_y;
0127     XtPointer   pad[2];     /* leave some space for further optimizations
0128                  * in the form widget geometry
0129                  */
0130 #endif
0131 } FormConstraintsPart;
0132 
0133 typedef struct _FormConstraintsRec {
0134     FormConstraintsPart form;
0135 } FormConstraintsRec, *FormConstraints;
0136 
0137 _XFUNCPROTOEND
0138 
0139 #endif /* _XawFormP_h */