diff --git a/sys/man/1/faces b/sys/man/1/faces index 633fb688b..eebc78c10 100644 --- a/sys/man/1/faces +++ b/sys/man/1/faces @@ -4,7 +4,7 @@ faces, seemail, vwhois \- mailbox interface .SH SYNOPSIS .B faces [ -.B -ih +.B -ihc ] [ .B -m .I maildir @@ -86,6 +86,12 @@ Multiple .B -m flags may be used to watch multiple mailboxes. .PP +Starting +.I faces +with the +.B -c +flag allows the user to remove faces with a click with button 1. +.PP The .B -h flag causes a different, venerable behavior in which diff --git a/sys/src/cmd/faces/main.c b/sys/src/cmd/faces/main.c index d5c2568de..3e3a511f1 100644 --- a/sys/src/cmd/faces/main.c +++ b/sys/src/cmd/faces/main.c @@ -9,6 +9,7 @@ int history = 0; /* use old interface, showing history of mailbox rather than current state */ int initload = 0; /* initialize program with contents of mail box */ +int clickrm = 0; /* allows removing mail faces by left clicking */ enum { @@ -600,7 +601,7 @@ click(int button, Mouse *m) }else{ for(i=first; istr[Sshow], "/XXXvwhois")){ + && (clickrm || strstr(faces[i]->str[Sshow], "/XXXvwhois"))){ delface(i); flushimage(display, 1); } @@ -675,7 +676,7 @@ startproc(void (*f)(void), int index) void usage(void) { - fprint(2, "usage: faces [-hi] [-m maildir]\n"); + fprint(2, "usage: faces [-chi] [-m maildir]\n"); exits("usage"); } @@ -695,6 +696,9 @@ main(int argc, char *argv[]) addmaildir(EARGF(usage())); maildir = nil; break; + case 'c': + clickrm++; + break; default: usage(); }ARGEND