1 /* @(#)$Id: fmtcompile.h,v 1.10 1993/06/12 06:46:16 jromine Exp $ */
6 /* types that output text */
7 #define FT_COMP 1 /* the text of a component */
8 #define FT_COMPF 2 /* comp text, filled */
9 #define FT_LIT 3 /* literal text */
10 #define FT_LITF 4 /* literal text, filled */
11 #define FT_CHAR 5 /* a single ascii character */
12 #define FT_NUM 6 /* "value" as decimal number */
13 #define FT_NUMF 7 /* "value" as filled dec number */
14 #define FT_STR 8 /* "str" as text */
15 #define FT_STRF 9 /* "str" as text, filled */
16 #define FT_STRFW 10 /* "str" as text, filled, width in "value" */
17 #define FT_PUTADDR 11 /* split and print address line */
19 /* types that modify the "str" or "value" registers */
20 #define FT_LS_COMP 12 /* set "str" to component text */
21 #define FT_LS_LIT 13 /* set "str" to literal text */
22 #define FT_LS_GETENV 14 /* set "str" to getenv(text) */
23 #define FT_LS_MFIND 15 /* set "str" to m_find(text) */
24 #define FT_LS_TRIM 16 /* trim trailing white space from "str" */
25 #define FT_LV_COMP 17 /* set "value" to comp (as dec. num) */
26 #define FT_LV_COMPFLAG 18 /* set "value" to comp flag word */
27 #define FT_LV_LIT 19 /* set "value" to literal num */
28 #define FT_LV_DAT 20 /* set "value" to dat[n] */
29 #define FT_LV_STRLEN 21 /* set "value" to length of "str" */
30 #define FT_LV_PLUS_L 22 /* set "value" += literal */
31 #define FT_LV_MINUS_L 23 /* set "value" -= literal */
32 #define FT_LV_DIVIDE_L 24 /* set "value" to value / literal */
33 #define FT_LV_MODULO_L 25 /* set "value" to value % literal */
34 #define FT_LV_CHAR_LEFT 26 /* set "value" to char left in output */
36 #define FT_LS_MONTH 27 /* set "str" to tws month */
37 #define FT_LS_LMONTH 28 /* set "str" to long tws month */
38 #define FT_LS_ZONE 29 /* set "str" to tws timezone */
39 #define FT_LS_DAY 30 /* set "str" to tws weekday */
40 #define FT_LS_WEEKDAY 31 /* set "str" to long tws weekday */
41 #define FT_LS_822DATE 32 /* set "str" to 822 date str */
42 #define FT_LS_PRETTY 33 /* set "str" to pretty (?) date str */
43 #define FT_LV_SEC 34 /* set "value" to tws second */
44 #define FT_LV_MIN 35 /* set "value" to tws minute */
45 #define FT_LV_HOUR 36 /* set "value" to tws hour */
46 #define FT_LV_MDAY 37 /* set "value" to tws day of month */
47 #define FT_LV_MON 38 /* set "value" to tws month */
48 #define FT_LV_YEAR 39 /* set "value" to tws year */
49 #define FT_LV_YDAY 40 /* set "value" to tws day of year */
50 #define FT_LV_WDAY 41 /* set "value" to tws weekday */
51 #define FT_LV_ZONE 42 /* set "value" to tws timezone */
52 #define FT_LV_CLOCK 43 /* set "value" to tws clock */
53 #define FT_LV_RCLOCK 44 /* set "value" to now - tws clock */
54 #define FT_LV_DAYF 45 /* set "value" to tws day flag */
55 #define FT_LV_DST 46 /* set "value" to tws daylight savings flag */
56 #define FT_LV_ZONEF 47 /* set "value" to tws timezone flag */
58 #define FT_LS_PERS 48 /* set "str" to person part of addr */
59 #define FT_LS_MBOX 49 /* set "str" to mbox part of addr */
60 #define FT_LS_HOST 50 /* set "str" to host part of addr */
61 #define FT_LS_PATH 51 /* set "str" to route part of addr */
62 #define FT_LS_GNAME 52 /* set "str" to group part of addr */
63 #define FT_LS_NOTE 53 /* set "str" to comment part of addr */
64 #define FT_LS_ADDR 54 /* set "str" to mbox@host */
65 #define FT_LS_822ADDR 55 /* set "str" to 822 format addr */
66 #define FT_LS_FRIENDLY 56 /* set "str" to "friendly" format addr */
67 #define FT_LV_HOSTTYPE 57 /* set "value" to addr host type */
68 #define FT_LV_INGRPF 58 /* set "value" to addr in-group flag */
69 #define FT_LV_NOHOSTF 59 /* set "value" to addr no-host flag */
72 #define FT_LOCALDATE 60 /* Coerce date to local timezone */
73 #define FT_GMTDATE 61 /* Coerce date to gmt */
75 /* pre-format processing */
76 #define FT_PARSEDATE 62 /* parse comp into a date (tws) struct */
77 #define FT_PARSEADDR 63 /* parse comp into a mailaddr struct */
78 #define FT_FORMATADDR 64 /* let external routine format addr */
79 #define FT_MYMBOX 65 /* do "mymbox" test on comp */
81 /* misc. */ /* ADDTOSEQ only works if you include "options LBL" */
82 #define FT_ADDTOSEQ 66 /* add current msg to a sequence */
84 /* conditionals & control flow (must be last) */
85 #define FT_SAVESTR 67 /* save current str reg */
86 #define FT_DONE 68 /* stop formatting */
87 #define FT_PAUSE 69 /* pause */
88 #define FT_NOP 70 /* nop */
89 #define FT_GOTO 71 /* (relative) goto */
90 #define FT_IF_S_NULL 72 /* test if "str" null */
91 #define FT_IF_S 73 /* test if "str" non-null */
92 #define FT_IF_V_EQ 74 /* test if "value" = literal */
93 #define FT_IF_V_NE 75 /* test if "value" != literal */
94 #define FT_IF_V_GT 76 /* test if "value" > literal */
95 #define FT_IF_MATCH 77 /* test if "str" contains literal */
96 #define FT_IF_AMATCH 78 /* test if "str" starts with literal */
97 #define FT_S_NULL 79 /* V = 1 if "str" null */
98 #define FT_S_NONNULL 80 /* V = 1 if "str" non-null */
99 #define FT_V_EQ 81 /* V = 1 if "value" = literal */
100 #define FT_V_NE 82 /* V = 1 if "value" != literal */
101 #define FT_V_GT 83 /* V = 1 if "value" > literal */
102 #define FT_V_MATCH 84 /* V = 1 if "str" contains literal */
103 #define FT_V_AMATCH 85 /* V = 1 if "str" starts with literal */
105 #define IF_FUNCS FT_S_NULL /* start of "if" functions */