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