Andreas Krennmair:
[apps/madmutt.git] / globals.h
1 /*
2  * Copyright (C) 1996-2002 Michael R. Elkins <me@mutt.org>
3  * 
4  *     This program is free software; you can redistribute it and/or modify
5  *     it under the terms of the GNU General Public License as published by
6  *     the Free Software Foundation; either version 2 of the License, or
7  *     (at your option) any later version.
8  * 
9  *     This program is distributed in the hope that it will be useful,
10  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
11  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  *     GNU General Public License for more details.
13  * 
14  *     You should have received a copy of the GNU General Public License
15  *     along with this program; if not, write to the Free Software
16  *     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
17  */ 
18
19 WHERE void (*mutt_error) (const char *, ...);
20 WHERE void (*mutt_message) (const char *, ...);
21
22 WHERE CONTEXT *Context;
23
24 WHERE char Errorbuf[STRING];
25 WHERE char AttachmentMarker[STRING];
26
27 WHERE char Quotebuf[SHORT_STRING];
28
29 #if defined(DL_STANDALONE) && defined(USE_DOTLOCK)
30 WHERE char *MuttDotlock;
31 #endif
32
33 WHERE ADDRESS *From;
34
35 WHERE char *AliasFile;
36 WHERE char *AliasFmt;
37 WHERE char *AttachSep;
38 WHERE char *Attribution;
39 WHERE char *AttachFormat;
40 WHERE char *Charset;
41 WHERE char *ComposeFormat;
42 WHERE char *ContentType;
43 WHERE char *DefaultHook;
44 WHERE char *DateFmt;
45 WHERE char *DisplayFilter;
46 WHERE char *DsnNotify;
47 WHERE char *DsnReturn;
48 WHERE char *Editor;
49 WHERE char *EscChar;
50 WHERE char *FolderFormat;
51 WHERE char *ForwFmt;
52 WHERE char *Fqdn;
53 WHERE char *HdrFmt;
54 WHERE char *Homedir;
55 WHERE char *Hostname;
56 #ifdef USE_IMAP
57 WHERE char *ImapAuthenticators INITVAL (NULL);
58 WHERE char *ImapDelimChars INITVAL (NULL);
59 WHERE char *ImapHomeNamespace INITVAL (NULL);
60 WHERE char *ImapPass INITVAL (NULL);
61 WHERE char *ImapUser INITVAL (NULL);
62 #endif
63 WHERE char *Inbox;
64 WHERE char *Ispell;
65 WHERE char *Locale;
66 WHERE char *MailcapPath;
67 WHERE char *Maildir;
68 #if USE_HCACHE
69 WHERE char *HeaderCache;
70 WHERE char *HeaderCachePageSize;
71 #endif
72 WHERE char *MhFlagged;
73 WHERE char *MhReplied;
74 WHERE char *MhUnseen;
75 WHERE char *MsgFmt;
76
77 #ifdef USE_SOCKET
78 WHERE char *Preconnect INITVAL (NULL);
79 WHERE char *Tunnel INITVAL (NULL);
80 #endif /* USE_SOCKET */
81
82 #ifdef MIXMASTER
83 WHERE char *Mixmaster;
84 WHERE char *MixEntryFormat;
85 #endif
86
87 WHERE char *OperatingSystem INITVAL (NULL);
88
89 WHERE char *Muttrc INITVAL (NULL);
90 #ifdef USE_NNTP
91 WHERE char *NewsCacheDir;
92 WHERE char *GroupFormat;
93 WHERE char *Inews;
94 WHERE char *NewsServer;
95 WHERE char *NntpUser;
96 WHERE char *NntpPass;
97 WHERE char *NewsRc;
98 #endif
99 WHERE char *Outbox;
100 WHERE char *Pager;
101 WHERE char *PagerFmt;
102 WHERE char *PipeSep;
103 #ifdef USE_POP
104 WHERE char *PopAuthenticators INITVAL (NULL);
105 WHERE short PopCheckTimeout;
106 WHERE char *PopHost;
107 WHERE char *PopPass INITVAL (NULL);
108 WHERE char *PopUser INITVAL (NULL);
109 #endif
110 WHERE char *PostIndentString;
111 WHERE char *Postponed;
112 WHERE char *Prefix;
113 WHERE char *PrintCmd;
114 WHERE char *QueryCmd;
115 WHERE char *Realname;
116 WHERE char *SendCharset;
117 WHERE char *Sendmail;
118 WHERE char *Shell;
119 WHERE char *Signature;
120 WHERE char *SimpleSearch;
121 #if defined(USE_LIBESMTP)
122 WHERE char *SmtpAuthUser;
123 WHERE char *SmtpAuthPass;
124 WHERE char *SmtpHost;
125 WHERE unsigned short SmtpPort;
126 #endif
127 WHERE char *Spoolfile;
128 #if defined(USE_SSL) || defined(USE_NSS) || defined(USE_GNUTLS)
129 WHERE char *SslCertFile INITVAL (NULL);
130 #endif
131 #if defined(USE_SSL) || defined(USE_NSS)
132 WHERE char *SslEntropyFile INITVAL (NULL);
133 #endif
134 #ifdef USE_GNUTLS
135 WHERE short SslDHPrimeBits;
136 WHERE char *SslCACertFile INITVAL (NULL);
137 #endif
138 WHERE char *StChars;
139 WHERE char *Status;
140 WHERE char *Tempdir;
141 WHERE char *Tochars;
142 WHERE char *TrashPath;
143 WHERE char *Username;
144 WHERE char *Visual;
145 WHERE char *XtermTitle;
146 WHERE char *XtermIcon;
147
148 WHERE char *LastFolder;
149
150 WHERE LIST *AutoViewList INITVAL(0);
151 WHERE LIST *AlternativeOrderList INITVAL(0);
152 WHERE LIST *HeaderOrderList INITVAL(0);
153 WHERE LIST *Ignore INITVAL(0);
154 WHERE LIST *MimeLookupList INITVAL(0);
155 WHERE LIST *UnIgnore INITVAL(0);
156
157 WHERE RX_LIST *Alternates INITVAL(0);
158 WHERE RX_LIST *MailLists INITVAL(0);
159 WHERE RX_LIST *SubscribedLists INITVAL(0);
160
161 /* bit vector for boolean variables */
162 #ifdef MAIN_C
163 unsigned char Options[(OPTMAX + 7)/8];
164 #else
165 extern unsigned char Options[];
166 #endif
167
168 /* bit vector for the yes/no/ask variable type */
169 #ifdef MAIN_C
170 unsigned char QuadOptions[(OPT_MAX*2 + 7) / 8];
171 #else
172 extern unsigned char QuadOptions[];
173 #endif
174
175 WHERE unsigned short Counter INITVAL (0);
176
177 #ifdef USE_NNTP
178 WHERE short NewsPollTimeout;
179 WHERE short NntpContext;
180 #endif
181
182 WHERE short ConnectTimeout;
183 WHERE short HistSize;
184 WHERE short PagerContext;
185 WHERE short PagerIndexLines;
186 WHERE short ReadInc;
187 WHERE short SendmailWait;
188 WHERE short SleepTime INITVAL (1);
189 WHERE short Timeout;
190 WHERE short Umask INITVAL(0077);
191 WHERE short WrapMargin;
192 WHERE short WriteInc;
193
194 WHERE short ScoreThresholdDelete;
195 WHERE short ScoreThresholdRead;
196 WHERE short ScoreThresholdFlag;
197
198 WHERE struct buffy_t *CurBuffy INITVAL(0);
199 WHERE short DrawFullLine INITVAL(0);
200 WHERE short SidebarWidth;
201 #ifdef USE_IMAP
202 WHERE short ImapKeepalive;
203 #endif
204
205 /* flags for received signals */
206 WHERE SIG_ATOMIC_VOLATILE_T SigAlrm INITVAL (0);
207 WHERE SIG_ATOMIC_VOLATILE_T SigInt INITVAL (0);
208 WHERE SIG_ATOMIC_VOLATILE_T SigWinch INITVAL (0);
209
210 WHERE int CurrentMenu;
211
212 WHERE ALIAS *Aliases INITVAL (0);
213 WHERE LIST *UserHeader INITVAL (0);
214
215 /*-- formerly in pgp.h --*/
216 WHERE REGEXP PgpGoodSign;
217 WHERE char *PgpSignAs;
218 WHERE short PgpTimeout;
219 WHERE char *PgpEntryFormat;
220 WHERE char *PgpClearSignCommand;
221 WHERE char *PgpDecodeCommand;
222 WHERE char *PgpVerifyCommand;
223 WHERE char *PgpDecryptCommand;
224 WHERE char *PgpSignCommand;
225 WHERE char *PgpEncryptSignCommand;
226 WHERE char *PgpEncryptOnlyCommand;
227 WHERE char *PgpImportCommand;
228 WHERE char *PgpExportCommand;
229 WHERE char *PgpVerifyKeyCommand;
230 WHERE char *PgpListSecringCommand;
231 WHERE char *PgpListPubringCommand;
232 WHERE char *PgpGetkeysCommand;
233
234 /*-- formerly in smime.h --*/
235 WHERE char *SmimeDefaultKey;
236 WHERE char *SmimeCryptAlg;
237 WHERE short SmimeTimeout;
238 WHERE char *SmimeCertificates;
239 WHERE char *SmimeKeys;
240 WHERE char *SmimeCryptAlg;
241 WHERE char *SmimeCALocation;
242 WHERE char *SmimeVerifyCommand;
243 WHERE char *SmimeVerifyOpaqueCommand;
244 WHERE char *SmimeDecryptCommand;
245 WHERE char *SmimeSignCommand;
246 WHERE char *SmimeSignOpaqueCommand;
247 WHERE char *SmimeEncryptCommand;
248 WHERE char *SmimeGetSignerCertCommand;
249 WHERE char *SmimePk7outCommand;
250 WHERE char *SmimeGetCertCommand;
251 WHERE char *SmimeImportCertCommand;
252 WHERE char *SmimeGetCertEmailCommand;
253
254
255
256 #ifdef DEBUG
257 WHERE FILE *debugfile INITVAL (0);
258 WHERE int debuglevel INITVAL (0);
259 #endif
260
261 #ifdef MAIN_C
262 const char *Weekdays[] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
263 const char *Months[] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "ERR" };
264
265 const char *BodyTypes[] = { "x-unknown", "audio", "application", "image", "message", "model", "multipart", "text", "video" };
266 const char *BodyEncodings[] = { "x-unknown", "7bit", "8bit", "quoted-printable", "base64", "binary", "x-uuencoded" };
267 #else
268 extern const char *Weekdays[];
269 extern const char *Months[];
270 #endif
271
272 #ifdef MAIN_C
273 /* so that global vars get included */ 
274 #include "mx.h"
275 #include "mutt_regex.h"
276 #include "buffy.h"
277 #include "sort.h"
278 #include "mutt_crypt.h"
279 #endif /* MAIN_C */