| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
#ifndef _TIX_FORM_H |
| 18 |
#define _TIX_FORM_H |
| 19 |
|
| 20 |
#define SIDE0 0 |
| 21 |
#define SIDE1 1 |
| 22 |
|
| 23 |
#define NEXT_SIDE(x) (!x) |
| 24 |
|
| 25 |
#define SIDEX 0 |
| 26 |
#define SIDEY 1 |
| 27 |
|
| 28 |
#define AXIS_X 0 |
| 29 |
#define AXIS_Y 1 |
| 30 |
|
| 31 |
#define OPPO_SIDE0 1 |
| 32 |
#define OPPO_SIDE1 2 |
| 33 |
#define OPPO_ALL 3 |
| 34 |
|
| 35 |
#define PINNED_SIDE0 4 |
| 36 |
#define PINNED_SIDE1 8 |
| 37 |
#define PINNED_ALL 12 |
| 38 |
|
| 39 |
#define ATT_NONE 0 |
| 40 |
#define ATT_GRID 1 |
| 41 |
#define ATT_OPPOSITE 2 |
| 42 |
#define ATT_PARALLEL 3 |
| 43 |
|
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
typedef union { |
| 48 |
int grid; |
| 49 |
struct _FormInfo * widget; |
| 50 |
} Attachment; |
| 51 |
|
| 52 |
typedef struct { |
| 53 |
int pcnt; |
| 54 |
int disp; |
| 55 |
} Side; |
| 56 |
|
| 57 |
typedef struct _FormInfo { |
| 58 |
Tk_Window tkwin; |
| 59 |
struct _MasterInfo* master; |
| 60 |
struct _FormInfo * next; |
| 61 |
|
| 62 |
int depend; |
| 63 |
|
| 64 |
|
| 65 |
|
| 66 |
Attachment att[2][2]; |
| 67 |
int off[2][2]; |
| 68 |
char isDefault[2][2]; |
| 69 |
|
| 70 |
char attType[2][2]; |
| 71 |
|
| 72 |
int pad[2][2]; |
| 73 |
|
| 74 |
|
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
Side side[2][2]; |
| 80 |
int sideFlags[2]; |
| 81 |
|
| 82 |
|
| 83 |
|
| 84 |
int posn[2][2]; |
| 85 |
|
| 86 |
|
| 87 |
int spring[2][2]; |
| 88 |
struct _FormInfo * strWidget[2][2]; |
| 89 |
int springFail[2]; |
| 90 |
int fill[2]; |
| 91 |
} FormInfo; |
| 92 |
|
| 93 |
|
| 94 |
|
| 95 |
|
| 96 |
|
| 97 |
typedef struct { |
| 98 |
unsigned int isDeleted : 1; |
| 99 |
unsigned int repackPending : 1; |
| 100 |
} MasterFlags; |
| 101 |
|
| 102 |
typedef struct _MasterInfo { |
| 103 |
Tk_Window tkwin; |
| 104 |
struct _FormInfo * client; |
| 105 |
struct _FormInfo * client_tail; |
| 106 |
int numClients; |
| 107 |
int reqSize[2]; |
| 108 |
int numRequests; |
| 109 |
|
| 110 |
|
| 111 |
|
| 112 |
|
| 113 |
int grids[2]; |
| 114 |
MasterFlags flags; |
| 115 |
} MasterInfo; |
| 116 |
|
| 117 |
|
| 118 |
|
| 119 |
|
| 120 |
EXTERN int TixFm_Configure _ANSI_ARGS_((FormInfo *clientPtr, |
| 121 |
Tk_Window topLevel, |
| 122 |
Tcl_Interp* interp, int argc, char **argv)); |
| 123 |
|
| 124 |
|
| 125 |
EXTERN FormInfo * TixFm_GetFormInfo _ANSI_ARGS_((Tk_Window tkwin, |
| 126 |
int create)); |
| 127 |
EXTERN void TixFm_StructureProc _ANSI_ARGS_((ClientData clientData, |
| 128 |
XEvent * eventPtr)); |
| 129 |
EXTERN void TixFm_AddToMaster _ANSI_ARGS_((MasterInfo *masterPtr, |
| 130 |
FormInfo *clientPtr)); |
| 131 |
EXTERN void TixFm_DeleteMaster _ANSI_ARGS_(( |
| 132 |
MasterInfo *masterPtr)); |
| 133 |
EXTERN void TixFm_FreeMasterInfo _ANSI_ARGS_(( |
| 134 |
char *clientData)); |
| 135 |
EXTERN FormInfo * TixFm_FindClientPtrByName _ANSI_ARGS_(( |
| 136 |
Tcl_Interp * interp, char * name, |
| 137 |
Tk_Window topLevel)); |
| 138 |
EXTERN void TixFm_ForgetOneClient _ANSI_ARGS_(( |
| 139 |
FormInfo *clientPtr)); |
| 140 |
EXTERN void TixFm_Unlink _ANSI_ARGS_((FormInfo *clientPtr)); |
| 141 |
EXTERN void TixFm_UnlinkFromMaster _ANSI_ARGS_(( |
| 142 |
FormInfo *clientPtr)); |
| 143 |
#endif |