Blame | Last modification | View Log | Download
/** %W% %G% %U%** tsprintf.h - structures and function prototypes for tsprintf** moved from tsprintf.c 01/11/89, iwb**/union value{long longv;unsigned long ulongv;};union argp{char **charpp;int *intp;unsigned int *uintp;long *longp;unsigned long *ulongp;double *doublep;};struct options{union value value;union argp argp;int radix;int width;int prec;int pad;int just;int sign;unsigned flags;};char *ts_putnum (unsigned long, char *, int);char *ts_ltoa (long, char *, int);char *ts_ultoa (long, char *, int);char *ts_numeric(char *bp, struct options *options);char *format_str(char *tp, char *sp, struct options *options);char *format_long(char *bp, long value, struct options *options);char *format_double(char *bp, double value, struct options *options);char *format_either(char *bp, double value, struct options *options);char *format_exp(char *bp, double value, struct options *options);#ifndef NUL#define NUL 0#endif/** flags ....*/#define TS_LFLAG 0x1 /* long flag */#define TS_UFLAG 0x2 /* unsigned flag */#define TS_UCASE 0x4 /* upper case conversion */#define TS_FTRUNC 0x8 /* truncate floating point zeros */#define USE_FLOAT 1 /* include floating point *//** states of precision ...*/#define NOPRECISION (-1) /* no precision specified */#define PRECMISSING (-2) /* period without precision */