[9657] | 1 | /* |
---|
| 2 | * $XConsortium: xmh.h,v 2.31 91/04/02 19:28:34 gildea Exp $ |
---|
| 3 | * |
---|
| 4 | * |
---|
| 5 | * COPYRIGHT 1987 |
---|
| 6 | * DIGITAL EQUIPMENT CORPORATION |
---|
| 7 | * MAYNARD, MASSACHUSETTS |
---|
| 8 | * ALL RIGHTS RESERVED. |
---|
| 9 | * |
---|
| 10 | * THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE WITHOUT NOTICE AND |
---|
| 11 | * SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT CORPORATION. |
---|
| 12 | * DIGITAL MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THIS SOFTWARE FOR |
---|
| 13 | * ANY PURPOSE. IT IS SUPPLIED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. |
---|
| 14 | * |
---|
| 15 | * IF THE SOFTWARE IS MODIFIED IN A MANNER CREATING DERIVATIVE COPYRIGHT |
---|
| 16 | * RIGHTS, APPROPRIATE LEGENDS MAY BE PLACED ON THE DERIVATIVE WORK IN |
---|
| 17 | * ADDITION TO THAT SET FORTH ABOVE. |
---|
| 18 | * |
---|
| 19 | * Permission to use, copy, modify, and distribute this software and its |
---|
| 20 | * documentation for any purpose and without fee is hereby granted, provided |
---|
| 21 | * that the above copyright notice appear in all copies and that both that |
---|
| 22 | * copyright notice and this permission notice appear in supporting |
---|
| 23 | * documentation, and that the name of Digital Equipment Corporation not be |
---|
| 24 | * used in advertising or publicity pertaining to distribution of the software |
---|
| 25 | * without specific, written prior permission. |
---|
| 26 | */ |
---|
| 27 | |
---|
| 28 | #ifndef _xmh_h |
---|
| 29 | #define _xmh_h |
---|
| 30 | |
---|
| 31 | #include <X11/Intrinsic.h> |
---|
| 32 | #include <X11/StringDefs.h> |
---|
| 33 | #include <X11/Shell.h> |
---|
| 34 | #include <X11/Xos.h> |
---|
| 35 | #include <X11/Xfuncs.h> |
---|
| 36 | #include <X11/Xutil.h> |
---|
| 37 | #include <X11/cursorfont.h> |
---|
| 38 | #include <X11/Xaw/AsciiText.h> |
---|
| 39 | #include <X11/Xaw/SmeBSB.h> |
---|
| 40 | #include <X11/Xaw/Box.h> |
---|
| 41 | #include <X11/Xaw/Command.h> |
---|
| 42 | #include <X11/Xaw/Dialog.h> |
---|
| 43 | #include <X11/Xaw/Form.h> |
---|
| 44 | #include <X11/Xaw/Label.h> |
---|
| 45 | #include <X11/Xaw/SmeLine.h> |
---|
| 46 | #include <X11/Xaw/MenuButton.h> |
---|
| 47 | #include <X11/Xaw/SimpleMenu.h> |
---|
| 48 | #include <X11/Xaw/Toggle.h> |
---|
| 49 | #include <X11/Xaw/Viewport.h> |
---|
| 50 | #include <X11/Xaw/Paned.h> |
---|
| 51 | #include <stdio.h> |
---|
| 52 | |
---|
| 53 | #define DELETEABORTED -1 |
---|
| 54 | #define NEEDS_CONFIRMATION -1 |
---|
| 55 | #define MARKPOS 4 |
---|
| 56 | |
---|
| 57 | #define xMargin 2 |
---|
| 58 | #define yMargin 2 |
---|
| 59 | |
---|
| 60 | #define DEBUG(msg) \ |
---|
| 61 | if (app_resources.debug) \ |
---|
| 62 | {(void)fprintf(stderr, msg); (void)fflush(stderr);} |
---|
| 63 | |
---|
| 64 | #define DEBUG1(msg, arg) \ |
---|
| 65 | if (app_resources.debug) \ |
---|
| 66 | {(void)fprintf(stderr, msg, arg); (void)fflush(stderr);} |
---|
| 67 | |
---|
| 68 | #define DEBUG2(msg, arg1, arg2) \ |
---|
| 69 | if (app_resources.debug) \ |
---|
| 70 | {(void)fprintf(stderr,msg,arg1,arg2); (void)fflush(stderr);} |
---|
| 71 | |
---|
| 72 | typedef int * dp; /* For debugging. */ |
---|
| 73 | |
---|
| 74 | typedef FILE* FILEPTR; |
---|
| 75 | |
---|
| 76 | typedef struct _ButtonRec *Button; |
---|
| 77 | typedef struct _XmhButtonBoxRec *ButtonBox; |
---|
| 78 | typedef struct _TocRec *Toc; |
---|
| 79 | typedef struct _MsgRec *Msg; |
---|
| 80 | typedef struct _PickRec *Pick; |
---|
| 81 | |
---|
| 82 | typedef enum { |
---|
| 83 | Fignore, Fmove, Fcopy, Fdelete |
---|
| 84 | } FateType; |
---|
| 85 | |
---|
| 86 | typedef enum { |
---|
| 87 | STtocAndView, |
---|
| 88 | STview, |
---|
| 89 | STcomp, |
---|
| 90 | STpick |
---|
| 91 | } ScrnKind; |
---|
| 92 | |
---|
| 93 | typedef struct _StackRec { |
---|
| 94 | char *data; |
---|
| 95 | struct _StackRec *next; |
---|
| 96 | } StackRec, *Stack; |
---|
| 97 | |
---|
| 98 | |
---|
| 99 | typedef struct _ScrnRec { |
---|
| 100 | Widget parent; /* The parent widget of the scrn */ |
---|
| 101 | Widget widget; /* The pane widget for the scrn */ |
---|
| 102 | int mapped; /* TRUE only if we've mapped this screen. */ |
---|
| 103 | ScrnKind kind; /* What kind of scrn we have. */ |
---|
| 104 | ButtonBox mainbuttons; /* Main xmh control buttons. */ |
---|
| 105 | Widget folderlabel; /* Folder titlebar */ |
---|
| 106 | ButtonBox folderbuttons; /* Folder buttons. */ |
---|
| 107 | Widget toclabel; /* Toc titlebar. */ |
---|
| 108 | Widget tocwidget; /* Toc text. */ |
---|
| 109 | ButtonBox miscbuttons; /* optional miscellaneous command buttons */ |
---|
| 110 | Widget viewlabel; /* View titlebar. */ |
---|
| 111 | Widget viewwidget; /* View text. */ |
---|
| 112 | ButtonBox viewbuttons; /* View control buttons. */ |
---|
| 113 | char * curfolder; /* Currently selected folder name */ |
---|
| 114 | Toc toc; /* The table of contents. */ |
---|
| 115 | Msg msg; /* The message being viewed. */ |
---|
| 116 | Pick pick; /* Pick in this screen. */ |
---|
| 117 | XtTranslations edit_translations; /* Text widget translations */ |
---|
| 118 | XtTranslations read_translations; /* overridden by accelerators */ |
---|
| 119 | Msg assocmsg; /* Associated message for reply, etc. */ |
---|
| 120 | Window wait_window; /* InputOnly window with busy cursor */ |
---|
| 121 | Stack folder_stack; /* Stack of folder names */ |
---|
| 122 | } ScrnRec, *Scrn; |
---|
| 123 | |
---|
| 124 | |
---|
| 125 | typedef struct { |
---|
| 126 | int nummsgs; |
---|
| 127 | Msg *msglist; |
---|
| 128 | } MsgListRec, *MsgList; |
---|
| 129 | |
---|
| 130 | |
---|
| 131 | typedef struct { |
---|
| 132 | char *name; /* Name of this sequence. */ |
---|
| 133 | MsgList mlist; /* Messages in this sequence. */ |
---|
| 134 | } SequenceRec, *Sequence; |
---|
| 135 | |
---|
| 136 | |
---|
| 137 | #include "globals.h" |
---|
| 138 | #include "externs.h" |
---|
| 139 | #include "mlist.h" |
---|
| 140 | #include "bbox.h" |
---|
| 141 | #include "msg.h" |
---|
| 142 | #include "toc.h" |
---|
| 143 | |
---|
| 144 | #endif /* _xmh_h */ |
---|