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