* When the locale is not set up to UTF-8, alpine might determine the width
[alpine.git] / pith / mailpart.h
blobaad3fdc4c4f2f466ba45bb36ce265c48773aea9c
1 /*
2 * $Id: mailpart.h 1074 2008-06-04 00:08:43Z hubert@u.washington.edu $
4 * ========================================================================
5 * Copyright 2013-2017 Eduardo Chappa
6 * Copyright 2006-2008 University of Washington
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * ========================================================================
17 #ifndef PITH_MAILPART_INCLUDED
18 #define PITH_MAILPART_INCLUDED
21 #include "../pith/atttype.h"
22 #include "../pith/state.h"
25 #define MIME_MSG(t,s) ((t) == TYPEMESSAGE && (s) && !strucmp((s),"rfc822"))
27 #define MIME_DGST(t,s) ((t) == TYPEMULTIPART && (s) && !strucmp((s),"digest"))
29 /* Is this a message attachment? */
30 #define MIME_VCARD(t,s) ((((t) == TYPETEXT || (t) == TYPEAPPLICATION) \
31 && (s) && !strucmp((s),"DIRECTORY")) \
32 || ((t) == TYPETEXT \
33 && (s) && !strucmp((s),"X-VCARD")))
35 /* Is this a multipart signed? */
36 #define MIME_MULT_SIGNED(t,s) ((t) == TYPEMULTIPART && (s) && !strucmp((s),"signed"))
39 #define MIME_MSG_A(a) MIME_MSG((a)->body->type, (a)->body->subtype)
41 /* Is this a digest attachment? */
42 #define MIME_DGST_A(a) MIME_DGST((a)->body->type, (a)->body->subtype)
44 /* Is this a vCard attachment? */
45 #define MIME_VCARD_A(a) MIME_VCARD((a)->body->type, (a)->body->subtype)
48 /* exported protoypes */
51 #endif /* PITH_MAILPART_INCLUDED */