diff options
author | Taru Karttunen <taruti@taruti.net> | 2011-03-30 15:46:40 +0300 |
---|---|---|
committer | Taru Karttunen <taruti@taruti.net> | 2011-03-30 15:46:40 +0300 |
commit | e5888a1ffdae813d7575f5fb02275c6bb07e5199 (patch) | |
tree | d8d51eac403f07814b9e936eed0c9a79195e2450 /sys/src/cmd/faces/faces.h |
Import sources from 2011-03-30 iso image
Diffstat (limited to 'sys/src/cmd/faces/faces.h')
-rwxr-xr-x | sys/src/cmd/faces/faces.h | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/sys/src/cmd/faces/faces.h b/sys/src/cmd/faces/faces.h new file mode 100755 index 000000000..4d0ffbd7b --- /dev/null +++ b/sys/src/cmd/faces/faces.h @@ -0,0 +1,66 @@ +enum /* face strings */ +{ + Suser, + Sdomain, + Sshow, + Sdigest, + Nstring +}; + +enum +{ + Facesize = 48, +}; + +typedef struct Face Face; +typedef struct Facefile Facefile; + +struct Face +{ + Image *bit; /* unless there's an error, this is file->image */ + Image *mask; /* unless there's an error, this is file->mask */ + char *str[Nstring]; + int recent; + ulong time; + Tm tm; + int unknown; + Facefile *file; +}; + +/* + * Loading the files is slow enough on a dial-up line to be worth this trouble + */ +struct Facefile +{ + Image *image; + Image *mask; + ulong mtime; + ulong rdtime; + int ref; + char *file; + Facefile *next; +}; + +extern char date[]; +extern char *maildir; +extern char **maildirs; +extern int nmaildirs; + +Face* nextface(void); +void findbit(Face*); +void freeface(Face*); +void initplumb(void); +void killall(char*); +void showmail(Face*); +void delete(char*, char*); +void freefacefile(Facefile*); +Face* dirface(char*, char*); +void resized(void); +int alreadyseen(char*); +ulong dirlen(char*); + +void *emalloc(ulong); +void *erealloc(void*, ulong); +char *estrdup(char*); +char *findfile(Face*, char*, char*); +void addmaildir(char*); |