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