File indexing completed on 2025-01-18 10:15:26
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025 #ifndef _XmHierarchyP_h
0026 #define _XmHierarchyP_h
0027
0028 #if defined(VMS) || defined(__VMS)
0029 #include <X11/apienvset.h>
0030 #endif
0031
0032
0033
0034
0035 #include <Xm/ManagerP.h>
0036 #include <Xm/ExtP.h>
0037 #include <Xm/Hierarchy.h>
0038
0039
0040
0041
0042
0043 #ifdef __cplusplus
0044 extern "C" {
0045 #endif
0046
0047 #define IS_MAPPED (1L << 1)
0048 #define IS_COMPRESSED (1L << 2)
0049 #define PARENT_GONE (1L << 3)
0050 #define IS_SELECTED (1L << 4)
0051
0052
0053
0054
0055
0056
0057
0058
0059
0060 typedef struct _HierNodeInfo {
0061
0062
0063
0064
0065 XmHierarchyNodeState state;
0066 Widget parent;
0067 Widget insert_before;
0068
0069 Pixmap open_folder, close_folder;
0070
0071
0072
0073
0074
0075 Widget widget;
0076 Widget open_close_button;
0077
0078 struct _HierarchyConstraintRec ** children;
0079 Cardinal num_children;
0080 Cardinal alloc_attrs, alloc;
0081
0082 unsigned char status;
0083 } HierNodeInfo;
0084
0085 typedef struct _HierarchyConstraintRec {
0086 XmManagerConstraintPart manager;
0087 HierNodeInfo hierarchy;
0088 } HierarchyConstraintRec, XmHierarchyConstraintRec, *HierarchyConstraints;
0089
0090 typedef void (*XmHierarchyNodeProc)(HierarchyConstraints);
0091 typedef void (*XmHierarchyExtraNodeProc)(Widget, HierarchyConstraints);
0092 typedef void (*XmHierarchyBuildTableProc)(Widget,
0093 HierarchyConstraints, Cardinal *);
0094 typedef void (*XmHierarchyResetButtonProc)(Widget, HierarchyConstraints);
0095
0096 typedef struct {
0097
0098 XmHierarchyNodeProc change_node_state;
0099
0100 XmHierarchyNodeProc map_node;
0101 XmHierarchyNodeProc unmap_node;
0102
0103 XmHierarchyExtraNodeProc unmap_all_extra_nodes;
0104
0105 XmHierarchyBuildTableProc build_node_table;
0106
0107 XmHierarchyResetButtonProc reset_open_close_button;
0108
0109 XtCallbackProc toggle_node_state;
0110
0111 XtPointer extension;
0112 } HierarchyClassPart;
0113
0114 typedef struct _XmHierarchyClassRec {
0115 CoreClassPart core_class;
0116 CompositeClassPart composite_class;
0117 ConstraintClassPart constraint_class;
0118 XmManagerClassPart manager_class;
0119 HierarchyClassPart hierarchy_class;
0120 } XmHierarchyClassRec;
0121
0122 externalref XmHierarchyClassRec xmHierarchyClassRec;
0123
0124 typedef struct _HierarchyPart {
0125
0126
0127 Boolean auto_close;
0128 Boolean refigure_mode;
0129
0130 Dimension h_margin;
0131 Dimension v_margin;
0132 Pixmap open_folder, close_folder;
0133
0134 XtCallbackList node_state_callback;
0135
0136 XtCallbackList node_state_changed_callback;
0137
0138 XtCallbackList node_state_beg_end_callback;
0139
0140
0141
0142
0143
0144 HierarchyConstraintRec ** node_table;
0145 HierarchyConstraints top_node;
0146 Cardinal num_nodes, alloc_nodes;
0147 Pixmap def_open_folder, def_close_folder;
0148
0149 XtWorkProcId work_proc_id;
0150 } HierarchyPart;
0151
0152 typedef struct _XmHierarchyRec {
0153 CorePart core;
0154 CompositePart composite;
0155 ConstraintPart constraint;
0156 XmManagerPart manager;
0157 HierarchyPart hierarchy;
0158 } XmHierarchyRec;
0159
0160
0161
0162
0163
0164 typedef HierarchyPart XmHierarchyPart;
0165 typedef HierNodeInfo XmHierarchyConstraintPart;
0166
0167 #define XmHierarchy_auto_close(w) (((XmHierarchyWidget)(w))->hierarchy.auto_close)
0168 #define XmHierarchy_refigure_mode(w) (((XmHierarchyWidget)(w))->hierarchy.refigure_mode)
0169 #define XmHierarchy_h_margin(w) (((XmHierarchyWidget)(w))->hierarchy.h_margin)
0170 #define XmHierarchy_v_margin(w) (((XmHierarchyWidget)(w))->hierarchy.v_margin)
0171 #define XmHierarchy_open_folder(w) (((XmHierarchyWidget)(w))->hierarchy.open_folder)
0172 #define XmHierarchy_close_folder(w) (((XmHierarchyWidget)(w))->hierarchy.close_folder)
0173 #define XmHierarchy_node_state_callback(w) (((XmHierarchyWidget)(w))->hierarchy.node_state_callback)
0174 #define XmHierarchy_node_state_changed_callback(w) (((XmHierarchyWidget)(w))->hierarchy.node_state_changed_callback)
0175 #define XmHierarchy_node_state_beg_end_callback(w) (((XmHierarchyWidget)(w))->hierarchy.node_state_beg_end_callback)
0176 #define XmHierarchy_node_table(w) (((XmHierarchyWidget)(w))->hierarchy.node_table)
0177 #define XmHierarchy_top_node(w) (((XmHierarchyWidget)(w))->hierarchy.top_node)
0178 #define XmHierarchy_num_nodes(w) (((XmHierarchyWidget)(w))->hierarchy.num_nodes)
0179 #define XmHierarchy_alloc_nodes(w) (((XmHierarchyWidget)(w))->hierarchy.alloc_nodes)
0180 #define XmHierarchy_def_open_folder(w) (((XmHierarchyWidget)(w))->hierarchy.def_open_folder)
0181 #define XmHierarchy_def_close_folder(w) (((XmHierarchyWidget)(w))->hierarchy.def_close_folder)
0182 #define XmHierarchy_work_proc_id(w) (((XmHierarchyWidget)(w))->hierarchy.work_proc_id)
0183
0184 #define XmHierarchyC_state(constraints) ((constraints)->hierarchy.state)
0185 #define XmHierarchyC_parent(constraints) ((constraints)->hierarchy.parent)
0186 #define XmHierarchyC_insert_before(constraints) ((constraints)->hierarchy.insert_before)
0187 #define XmHierarchyC_open_folder(constraints) ((constraints)->hierarchy.open_folder)
0188 #define XmHierarchyC_close_folder(constraints) ((constraints)->hierarchy.close_folder)
0189 #define XmHierarchyC_widget(constraints) ((constraints)->hierarchy.widget)
0190 #define XmHierarchyC_open_close_button(constraints) ((constraints)->hierarchy.open_close_button)
0191 #define XmHierarchyC_children(constraints) ((constraints)->hierarchy.children)
0192 #define XmHierarchyC_num_children(constraints) ((constraints)->hierarchy.num_children)
0193 #define XmHierarchyC_alloc_attrs(constraints) ((constraints)->hierarchy.alloc_attrs)
0194 #define XmHierarchyC_alloc(constraints) ((constraints)->hierarchy.alloc)
0195 #define XmHierarchyC_status(constraints) ((constraints)->hierarchy.status)
0196
0197 #define XtInheritChangeNodeState ((XmHierarchyNodeProc)_XtInherit)
0198 #define XtInheritUnmapAllExtraNodes ((XmHierarchyExtraNodeProc)_XtInherit)
0199 #define XtInheritUnmapNode ((XmHierarchyNodeProc)_XtInherit)
0200 #define XtInheritMapNode ((XmHierarchyNodeProc)_XtInherit)
0201 #define XtInheritBuildNodeTable ((XmHierarchyBuildTableProc)_XtInherit)
0202 #define XtInheritResetOpenCloseButton ((XmHierarchyResetButtonProc)_XtInherit)
0203 #define XtInheritToggleNodeState ((XtCallbackProc)_XtInherit)
0204
0205
0206
0207
0208
0209
0210
0211
0212
0213
0214 #ifdef __cplusplus
0215 }
0216 #endif
0217
0218 #if defined(VMS) || defined(__VMS)
0219 #include <X11/apienvrst.h>
0220 #endif
0221
0222 #endif