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