fix compilation
[apps/madmutt.git] / globals.h
1 /*
2  * Copyright notice from original mutt:
3  * Copyright (C) 1996-2002 Michael R. Elkins <me@mutt.org>
4  *
5  * This file is part of mutt-ng, see http://www.muttng.org/.
6  * It's licensed under the GNU General Public License,
7  * please see the file GPL in the top level source directory.
8  */
9 #ifndef _GLOBALS_H
10 #define _GLOBALS_H
11
12 #include <lib-lib/lib-lib.h>
13
14 #include "lib/list.h"
15
16 WHERE void (*mutt_error) (const char *, ...);
17 WHERE void (*mutt_message) (const char *, ...);
18
19 WHERE CONTEXT *Context;
20
21 WHERE char Errorbuf[STRING];
22 WHERE char AttachmentMarker[STRING];
23
24 WHERE char Quotebuf[SHORT_STRING];
25
26 WHERE char *MuttDotlock;
27
28 WHERE address_t *EnvFrom;
29 WHERE address_t *From;
30
31 WHERE char *AssumedCharset;
32 WHERE char *AttachSep;
33 WHERE char *Attribution;
34 WHERE char *AttachFormat;
35 WHERE char *ComposeFormat;
36 WHERE char *ConfigCharset;
37 WHERE char *ContentType;
38 WHERE char *DefaultHook;
39 WHERE char *DateFmt;
40 WHERE char *DisplayFilter;
41 WHERE char *DsnNotify;
42 WHERE char *DsnReturn;
43 WHERE char *Editor;
44 WHERE char *EditorHeaders;
45 WHERE char *FileCharset;
46 WHERE char *FolderFormat;
47 WHERE char *ForwFmt;
48 WHERE char *Fqdn;
49 WHERE char *HdrFmt;
50 WHERE char *Homedir;
51 WHERE char *Hostname;
52
53 WHERE char *ImapAuthenticators INITVAL (NULL);
54 WHERE char *ImapDelimChars INITVAL (NULL);
55 WHERE char *ImapHeaders;
56 WHERE char *ImapHomeNamespace INITVAL (NULL);
57 WHERE char *ImapLogin INITVAL (NULL);
58 WHERE char *ImapPass INITVAL (NULL);
59 WHERE char *ImapUser INITVAL (NULL);
60 WHERE char *Inbox;
61 WHERE char *Ispell;
62 WHERE char *Locale;
63 WHERE char *MailcapPath;
64 WHERE char *Maildir;
65
66 #ifdef USE_HCACHE
67 WHERE char *HeaderCache;
68 #if defined(HAVE_GDBM) || defined(HAVE_DB4)
69 WHERE char *HeaderCachePageSize;
70 #endif /* HAVE_GDBM || HAVE_DB4 */
71 #endif /* USE_HCACHE */
72 WHERE char *MhFlagged;
73 WHERE char *MhReplied;
74 WHERE char *MhUnseen;
75 WHERE char *MsgFmt;
76 WHERE char *MsgIdFormat;
77
78 WHERE rx_t AttachRemindRegexp;
79 WHERE rx_t Mask;
80 WHERE rx_t QuoteRegexp;
81 WHERE rx_t ReplyRegexp;
82 WHERE rx_t Smileys;
83 WHERE rx_t StripWasRegexp;
84
85 WHERE char *Preconnect INITVAL (NULL);
86 WHERE char *Tunnel INITVAL (NULL);
87 WHERE short NetInc;
88
89 #ifdef MIXMASTER
90 WHERE char *Mixmaster;
91 WHERE char *MixEntryFormat;
92 #endif
93
94 WHERE char *OperatingSystem INITVAL (NULL);
95
96 WHERE char *Muttrc INITVAL (NULL);
97
98 #ifdef USE_NNTP
99 WHERE char *NewsCacheDir;
100 WHERE char *GroupFormat;
101 WHERE char *Inews;
102 WHERE char *NewsServer;
103 WHERE char *NntpUser;
104 WHERE char *NntpPass;
105 WHERE char *NewsRc;
106 #endif
107 WHERE char *Outbox;
108 WHERE char *Pager;
109 WHERE char *PagerFmt;
110 WHERE char *PipeSep;
111
112 WHERE char *PopAuthenticators INITVAL (NULL);
113 WHERE short PopCheckTimeout;
114 WHERE char *PopHost;
115 WHERE char *PopPass INITVAL (NULL);
116 WHERE char *PopUser INITVAL (NULL);
117
118 WHERE char *PostIndentString;
119 WHERE char *Postponed;
120 WHERE char *Prefix;
121 WHERE char *PrintCmd;
122 WHERE char *QueryCmd;
123 WHERE char *Realname;
124 WHERE char *SendCharset;
125 WHERE char *Sendmail;
126 WHERE char *Shell;
127 WHERE char *SidebarDelim;
128 WHERE char *SidebarNumberFormat;
129 WHERE char *SidebarBoundary;
130 WHERE char *Signature;
131 WHERE char *SignOffString;
132 WHERE char *SimpleSearch;
133
134 #if defined(USE_LIBESMTP)
135 WHERE char *SmtpAuthUser;
136 WHERE char *SmtpAuthPass;
137 WHERE char *SmtpHost;
138 WHERE unsigned short SmtpPort;
139 WHERE char *SmtpUseTLS;
140 #endif
141 WHERE char *Spoolfile;
142 WHERE char *SpamSep;
143
144 #if defined(USE_SSL) || defined(USE_GNUTLS)
145 WHERE char *SslCertFile INITVAL (NULL);
146 #endif
147 #if defined(USE_SSL)
148 WHERE char *SslEntropyFile INITVAL (NULL);
149 #endif
150 #ifdef USE_SSL
151 WHERE char *SslClientCert INITVAL (NULL);
152 WHERE string_list_t *SslSessionCerts INITVAL (NULL);
153 #endif
154 #ifdef USE_GNUTLS
155 WHERE short SslDHPrimeBits;
156 WHERE char *SslCACertFile INITVAL (NULL);
157 #endif
158 WHERE char *StChars;
159 WHERE char *Status;
160 WHERE char *Tempdir;
161 WHERE char *Tochars;
162 WHERE char *TrashPath;
163 WHERE char *Username;
164 WHERE char *XtermTitle;
165 WHERE char *XtermLeave;
166 WHERE char *XtermIcon;
167
168 WHERE char *CurrentFolder;
169 WHERE char *LastFolder;
170
171 WHERE string_list_t *AutoViewList INITVAL (0);
172 WHERE string_list_t *AlternativeOrderList INITVAL (0);
173 WHERE string_list_t *AttachAllow INITVAL(0);
174 WHERE string_list_t *AttachExclude INITVAL(0);
175 WHERE string_list_t *InlineAllow INITVAL(0);
176 WHERE string_list_t *InlineExclude INITVAL(0);
177 WHERE string_list_t *HeaderOrderList INITVAL (0);
178 WHERE string_list_t *Ignore INITVAL (0);
179 WHERE string_list_t *MimeLookupList INITVAL (0);
180 WHERE string_list_t *UnIgnore INITVAL (0);
181
182 WHERE list2_t *Alternates INITVAL (0);
183 WHERE list2_t *UnAlternates INITVAL (0);
184 WHERE list2_t *MailLists INITVAL (0);
185 WHERE list2_t *UnMailLists INITVAL (0);
186 WHERE list2_t *SubscribedLists INITVAL (0);
187 WHERE list2_t *UnSubscribedLists INITVAL (0);
188 WHERE SPAM_LIST *SpamList INITVAL (0);
189 WHERE list2_t *NoSpamList INITVAL (0);
190
191 /* bit vector for boolean variables */
192 #ifdef MAIN_C
193 unsigned char Options[(OPTMAX + 7) / 8];
194 #else
195 extern unsigned char Options[];
196 #endif
197
198 /* bit vector for the yes/no/ask variable type */
199 #ifdef MAIN_C
200 unsigned char QuadOptions[(OPT_MAX * 2 + 7) / 8];
201 #else
202 extern unsigned char QuadOptions[];
203 #endif
204
205 WHERE unsigned short Counter INITVAL (0);
206
207 #ifdef USE_NNTP
208 WHERE short NewsPollTimeout;
209 WHERE short NntpContext;
210 #endif
211
212 WHERE short ConnectTimeout;
213 WHERE short HistSize;
214 WHERE short MenuContext;
215 WHERE short PagerContext;
216 WHERE short PagerIndexLines;
217 WHERE short ReadInc;
218 WHERE short SendmailWait;
219 WHERE short SleepTime INITVAL (1);
220 WHERE short Timeout;
221 WHERE short Umask INITVAL (0077);
222 WHERE short WrapMargin;
223 WHERE short WriteInc;
224 WHERE short MaxDispRecips;
225 WHERE short MaxLineLength;
226
227 WHERE short ScoreThresholdDelete;
228 WHERE short ScoreThresholdRead;
229 WHERE short ScoreThresholdFlag;
230
231 WHERE short DrawFullLine INITVAL (0);
232 WHERE short SidebarWidth;
233
234 WHERE short ImapKeepalive;
235 WHERE short ImapBuffyTimeout;
236
237 /* flags for received signals */
238 WHERE SIG_ATOMIC_VOLATILE_T SigAlrm INITVAL (0);
239 WHERE SIG_ATOMIC_VOLATILE_T SigInt INITVAL (0);
240 WHERE SIG_ATOMIC_VOLATILE_T SigWinch INITVAL (0);
241
242 WHERE int CurrentMenu;
243
244 WHERE string_list_t *UserHeader INITVAL (0);
245
246 /*-- formerly in pgp.h --*/
247 WHERE rx_t PgpGoodSign;
248 WHERE char *PgpSignAs;
249 WHERE short PgpTimeout;
250 WHERE char *PgpEntryFormat;
251 WHERE char *PgpClearSignCommand;
252 WHERE char *PgpDecodeCommand;
253 WHERE char *PgpVerifyCommand;
254 WHERE char *PgpDecryptCommand;
255 WHERE char *PgpSignCommand;
256 WHERE char *PgpEncryptSignCommand;
257 WHERE char *PgpEncryptOnlyCommand;
258 WHERE char *PgpImportCommand;
259 WHERE char *PgpExportCommand;
260 WHERE char *PgpVerifyKeyCommand;
261 WHERE char *PgpListSecringCommand;
262 WHERE char *PgpListPubringCommand;
263 WHERE char *PgpGetkeysCommand;
264
265 /*-- formerly in smime.h --*/
266 WHERE char *SmimeDefaultKey;
267 WHERE char *SmimeCryptAlg;
268 WHERE short SmimeTimeout;
269 WHERE char *SmimeCertificates;
270 WHERE char *SmimeKeys;
271 WHERE char *SmimeCALocation;
272 WHERE char *SmimeVerifyCommand;
273 WHERE char *SmimeVerifyOpaqueCommand;
274 WHERE char *SmimeDecryptCommand;
275 WHERE char *SmimeSignCommand;
276 WHERE char *SmimeSignOpaqueCommand;
277 WHERE char *SmimeEncryptCommand;
278 WHERE char *SmimeGetSignerCertCommand;
279 WHERE char *SmimePk7outCommand;
280 WHERE char *SmimeGetCertCommand;
281 WHERE char *SmimeImportCertCommand;
282 WHERE char *SmimeGetCertEmailCommand;
283
284 #ifdef MAIN_C
285 const char *Weekdays[] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
286 const char *Months[] =
287   { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct",
288 "Nov", "Dec", "ERR" };
289 #else
290 extern const char *Weekdays[];
291 extern const char *Months[];
292 #endif
293
294 #endif /* !_GLOBALS_H */