home *** CD-ROM | disk | FTP | other *** search
Text File | 1990-07-09 | 42.3 KB | 1,308 lines |
- Newsgroups: comp.sources.misc
- subject: v13i108: Official patch #6 for faces v1.4 - please apply it.
- from: rburridge@Sun.COM (Rich Burridge)
- Sender: allbery@uunet.UU.NET (Brandon S. Allbery - comp.sources.misc)
-
- Posting-number: Volume 13, Issue 108
- Submitted-by: rburridge@Sun.COM (Rich Burridge)
- Archive-name: faces-1.4.5/patch01
-
- Brandon, could you please post this to comp.sources.misc (and subsequently
- archive it). I've also sent a copy to comp.sources.bugs.
-
- Thanks.
-
- Rich Burridge, DOMAIN: richb@Aus.Sun.COM
- PHONE: +61 2 413 2666 ACSnet: richb@sunaus.sun.oz.au
-
- ------CUT HERE------CUT HERE------
-
- This is official patch #6 to faces v1.4 - please apply it.
-
- [**NOTE: faces v1.4 was posted to comp.sources.misc at patchlevel #5. **]
-
- You should use the -p0 option to Larry Wall's patch program, to
- allow the patches for the filters directory files to be correctly
- applied. Then recompile, and reinstall. For example:
-
- # Save this news item in a file called "patchfile"
- cd faces_src
- patch -p0 <patchfile
- make xview # Or Sunview, X11 or NeWS.
- make install # You might have to be super-user.
-
- [Please note that I'm going to be overseas from the weekend until the
- first week in August, so if you send me any mail with bugs, fixes or
- enhancements, I probably won't reply until I return. Please don't let
- that stop you making a dent in the TODO list (which has grown again
- with this patch). :-) ]
-
- This patch makes the following changes:
-
- * From Tony Landells <ahl@technix.oz.au>
- Change all the .LP macros in the manual pages to .PP, since .PP is
- an alternative to .LP is newer versions of the manual pages, while
- it is the alternative to .P in older versions; but older versions
- don't have .LP and newer ones don't have .P. Thus .PP seems to be
- the only universally accepted one.
-
- * From Pat Lashley <patl@Sun.COM>
- make_iconname() is broken with respect to multi-level domains. One
- symptom is that `unknown' will always come from misc.. The problem
- is that the for loops are nested backwards.
-
- * From Pat Lashley <patl@Sun.COM>
- Code to impliment simple NIS lookup for hosts not explicitly
- mentioned in the machines table. Note there is another definition
- at the front of the Makefile (NISLOOKUP), then should be uncommented
- to use this feature. The README file has been updated.
-
- * From Dave Glowacki <dglo@ads.com>
- From Steven M. Miller <miller@SCTC.COM>
- If the geometry has been set with -geometry you don't want to try
- and get the default. Additionally if no default is set XGetDefault
- returns NULL which crashes the faces program.
-
- * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- For system V and varients, there is no <strings.h>; it is <string.h>.
- I've added yet another definition (SYSV) to the Makefile, that
- should be uncommented, if this is the case for your machine. The
- README file has been updated.
-
- * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- Making rs2icon fails because my machine has no rasterfile.h
- include file. The #include <rasterfile.h> has been removed from
- this file, and the structure definition added to the source file.
-
- * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- ikon2icon in the filters directory uses index(), so you have to do
- the NOINDEX define stuff there too.
-
- A copy of this patch has been sent to the moderator of comp.sources.misc,
- for posting, and subsequent archiving.
-
- ------- main.c -------
- *** /tmp/da18469 Thu Jul 5 16:57:42 1990
- --- main.c Thu Jul 5 15:49:42 1990
- ***************
- *** 17,28 ****
- --- 17,38 ----
- */
-
- #include <stdio.h>
- + #ifdef SYSV
- + #include <string.h>
- + #else
- #include <strings.h>
- + #endif /*SYSV*/
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <netdb.h>
- +
- + #ifdef NISLOOKUP
- + #include <rpcsvc/ypclnt.h>
- + #endif /*NISLOOKUP*/
- +
- #include "faces.h"
-
- +
- unsigned short noface_image[] = {
- #include "noface.icon"
- } ;
- ***************
- *** 73,79 ****
- char face_user[MAXLINE] ; /* Pointer to user name from the "From" line. */
- char facedir[MAXLINE] ; /* Alternate face image directory. */
- char fname[MAXTYPES][MAXLINE] ; /* Array of various face name types. */
- ! char geometry[MAXLINE] ; /* X11 geometry information. */
- char hostname[MAXLINE] ; /* Machine name to monitor. */
- char iconname[MAXLINE] ; /* Name of the icon file for this person. */
- char line[MAXLINE] ; /* Next line from users mail spool file. */
- --- 83,90 ----
- char face_user[MAXLINE] ; /* Pointer to user name from the "From" line. */
- char facedir[MAXLINE] ; /* Alternate face image directory. */
- char fname[MAXTYPES][MAXLINE] ; /* Array of various face name types. */
- ! char geometry[MAXLINE] ; /* X11 geometry information. */
- ! char hostcommunity[MAXLINE] ; /* The community of the host machine */
- char hostname[MAXLINE] ; /* Machine name to monitor. */
- char iconname[MAXLINE] ; /* Name of the icon file for this person. */
- char line[MAXLINE] ; /* Next line from users mail spool file. */
- ***************
- *** 88,93 ****
- --- 99,109 ----
- char *username ; /* This users name. */
- char userprog[MAXLINE] ; /* User supplied program to run. */
-
- + #ifdef NISLOOKUP
- + char *hostdomain ; /* NIS domain of host machine */
- + char domaincommunity[MAXLINE] ; /* Community for the current domain */
- + #endif /*NISLOOKUP*/
- +
- int beeps ; /* Number of beeps for arrival of new mail. */
- int column ; /* Column number for next icon. */
- int doing_xface = 0 ; /* Set if we've started to process an X-Face: */
- ***************
- *** 199,204 ****
- --- 215,258 ----
- #endif /*REVORDER*/
- make_area(DISP_ICON, imagewidth, imageheight) ;
-
- + /* Initialize the host community to the official name of the current host
- + * (or it's translation via the machines table.)
- + */
- +
- + {
- + struct hostent *hp ;
- + char hostname[MAXLINE] ;
- +
- + GETHOSTNAME(hostname, MAXLINE) ;
- + hp = gethostbyname (hostname) ;
- + if (hp != NULL) STRCPY(hostname, hp->h_name) ;
- + h_to_c(hostname, hostcommunity) ;
- + }
- +
- + #ifdef NISLOOKUP
- + {
- + struct machinfo *temp ;
- +
- + yp_get_default_domain (&hostdomain) ;
- + STRCPY(domaincommunity, hostdomain) ;
- +
- + /* We can't call h_to_c() to setup the default because it expects
- + * it to be set already; so we grovel through the machine/community
- + * association list directly.
- + */
- +
- + for (temp = machines; temp != NULL; temp = temp->next)
- + if (strcmp(temp->machine, domaincommunity) == 0)
- + {
- + STRCPY(domaincommunity, temp->community) ;
- + break ;
- + }
- +
- + IF_DEBUG( FPRINTF(stderr, "main: domain community is `%s`\n",
- + domaincommunity) ; )
- + }
- + #endif /*NISLOOKUP*/
- +
- make_icon() ; /* Create default faces icon. */
- make_frame(argc, argv) ; /* Create faces window/icon. */
- do_check() ; /* Generate initial faces display. */
- ***************
- *** 300,323 ****
- {
- struct hostent *hp ;
- struct machinfo *temp ; /* Pointer to next machine record. */
- !
- ! temp = machines ; /* Point to list of machine/communitys. */
- if (host[0] == '\0')
- {
- ! GETHOSTNAME(community, MAXLINE) ;
- ! hp = gethostbyname(community) ;
- ! if (hp != NULL) STRCPY(community, hp->h_name) ;
- }
- else STRCPY(community, host) ; /* Copied in case machine name not found. */
- ! while (temp != NULL)
- {
- ! if (!strcmp(temp->machine, community))
- ! {
- ! STRCPY(community, temp->community) ;
- ! return ;
- ! }
- ! temp = temp->next ; /* Point to next record. */
- }
- }
-
-
- --- 354,407 ----
- {
- struct hostent *hp ;
- struct machinfo *temp ; /* Pointer to next machine record. */
- ! char *hostinfo ; /* Info returned from yp_match */
- ! int len ; /* Length of returned hostinfo */
- ! int yp_err ; /* Result from yp_match() */
- !
- if (host[0] == '\0')
- {
- !
- ! /* Host not specified means use current host - return cached community. */
- !
- ! STRCPY(community, hostcommunity) ;
- ! return ;
- }
- else STRCPY(community, host) ; /* Copied in case machine name not found. */
- !
- ! /* Grovel through the machine/community association list. */
- !
- ! for (temp = machines; temp != NULL; temp = temp->next)
- ! if (strcmp(temp->machine, community) == 0)
- ! {
- ! STRCPY(community, temp->community) ;
- ! IF_DEBUG( FPRINTF(stderr,
- ! "h_to_c(): machine `%s` found in community '%s'\n",
- ! temp->machine, community) ; )
- ! return ;
- ! }
- !
- ! #ifdef NISLOOKUP
- !
- ! /* yp_match() returns zero on success. We will treat any failure as
- ! * a simple `no match' condition.
- ! */
- !
- ! yp_err = yp_match(hostdomain, "hosts.byname",
- ! host, strlen(host), &hostinfo, &len) ;
- !
- ! if (yp_err == 0)
- {
- !
- ! /* We aren't interested in the value returned, only whether the key
- ! * was found...
- ! */
- !
- ! STRCPY(community, domaincommunity) ;
- ! IF_DEBUG( FPRINTF(stderr, "NISlookup: found %s\n", host) ; )
- }
- + IF_DEBUG( else FPRINTF(stderr, "NISlookup: Error %d\n", yp_err) ; )
- + IF_DEBUG( FPRINTF(stderr, "h_to_c(): community = '%s'\n", community) ; )
- + #endif /*NISLOOKUP*/
- }
-
-
- ***************
- *** 346,354 ****
-
- old_style = 0 ; /* Reset before checking this face. */
-
- if (strlen(facedir))
- ! for (i = -1; i < maxtypes; i++)
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- --- 430,440 ----
-
- old_style = 0 ; /* Reset before checking this face. */
-
- + IF_DEBUG( FPRINTF(stderr, "make_iconname: %s[%s] ", community, user) ; )
- +
- if (strlen(facedir))
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- ! for (i = -1; i < maxtypes; i++)
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- ***************
- *** 358,363 ****
- --- 444,450 ----
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- old_style = 1 ;
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- return 1 ;
- }
- }
- ***************
- *** 364,376 ****
- else
- {
- SPRINTF(iconname, "%s/%s/%s/%s", facedir, cptr, user, fname[i]) ;
- ! if (stat(iconname, &buf) != -1) return 1 ;
- }
- }
-
- mi1:
- ! for (i = -1; i < maxtypes; i++)
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- --- 451,467 ----
- else
- {
- SPRINTF(iconname, "%s/%s/%s/%s", facedir, cptr, user, fname[i]) ;
- ! if (stat(iconname, &buf) != -1)
- ! {
- ! IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- ! return 1 ;
- ! }
- }
- }
-
- mi1:
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- ! for (i = -1; i < maxtypes; i++)
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- ***************
- *** 379,384 ****
- --- 470,476 ----
- if (stat(iconname, &buf) == -1) goto mi2 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 386,392 ****
- else
- {
- SPRINTF(iconname, "%s/%s/%s/%s", defdir, cptr, user, fname[i]) ;
- ! if (stat(iconname, &buf) != -1) return 1 ;
- }
- }
-
- --- 478,488 ----
- else
- {
- SPRINTF(iconname, "%s/%s/%s/%s", defdir, cptr, user, fname[i]) ;
- ! if (stat(iconname, &buf) != -1)
- ! {
- ! IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- ! return 1 ;
- ! }
- }
- }
-
- ***************
- *** 399,404 ****
- --- 495,501 ----
- if (stat(iconname, &buf) == -1) goto mi3 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 409,414 ****
- --- 506,512 ----
- if (stat(iconname, &buf) != -1)
- {
- if (!x_face) STRCPY(community, "misc.") ;
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- return 1 ;
- }
- }
- ***************
- *** 421,426 ****
- --- 519,525 ----
- if (stat(iconname, &buf) == -1) goto mi4 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 430,435 ****
- --- 529,535 ----
- SPRINTF(iconname, "%s/misc./%s/%s", defdir, user, fname[i]) ;
- if (stat(iconname, &buf) != -1)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- if (!x_face) STRCPY(community, "misc.") ;
- return 1 ;
- }
- ***************
- *** 437,444 ****
-
- mi4:
- if (strlen(facedir))
- ! for (i = -1; i < maxtypes; i++)
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- --- 537,544 ----
-
- mi4:
- if (strlen(facedir))
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- ! for (i = -1; i < maxtypes; i++)
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- ***************
- *** 447,452 ****
- --- 547,553 ----
- if (stat(iconname, &buf) == -1) goto mi5 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 456,461 ****
- --- 557,563 ----
- SPRINTF(iconname, "%s/%s/unknown/%s", facedir, cptr, fname[i]) ;
- if (stat(iconname, &buf) != -1)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- if (mtype == MONALL && !x_face) STRCPY(user, "unknown") ;
- return 1 ;
- }
- ***************
- *** 463,470 ****
- }
-
- mi5:
- ! for (i = -1; i < maxtypes; i++)
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- --- 565,572 ----
- }
-
- mi5:
- ! for (cptr = community; cptr != NULL; cptr = index(cptr, '.'))
- ! for (i = -1; i < maxtypes; i++)
- {
- if (*cptr == '.') cptr++ ;
- if (i < 0)
- ***************
- *** 473,478 ****
- --- 575,581 ----
- if (stat(iconname, &buf) == -1) goto mi6 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 482,487 ****
- --- 585,591 ----
- SPRINTF(iconname, "%s/%s/unknown/%s", defdir, cptr, fname[i]) ;
- if (stat(iconname, &buf) != -1)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- if (mtype == MONALL && !x_face) STRCPY(user, "unknown") ;
- return 1 ;
- }
- ***************
- *** 497,502 ****
- --- 601,607 ----
- if (stat(iconname, &buf) == -1) goto mi7 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 506,511 ****
- --- 611,617 ----
- SPRINTF(iconname, "%s/misc./unknown/%s", facedir, fname[i]) ;
- if (stat(iconname, &buf) != -1)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- if (!x_face) STRCPY(community, "misc.") ;
- if (mtype == MONALL && !x_face) STRCPY(user, "unknown") ;
- return 1 ;
- ***************
- *** 520,525 ****
- --- 626,632 ----
- if (stat(iconname, &buf) == -1) return 0 ;
- if ((buf.st_mode & S_IFMT) == S_IFREG)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- old_style = 1 ;
- return 1 ;
- }
- ***************
- *** 529,534 ****
- --- 636,642 ----
- SPRINTF(iconname, "%s/misc./unknown/%s", defdir, fname[i]) ;
- if (stat(iconname, &buf) != -1)
- {
- + IF_DEBUG( FPRINTF(stderr, "found as %s\n", iconname) ; )
- if (!x_face) STRCPY(community, "misc.") ;
- if (mtype == MONALL && !x_face) STRCPY(user, "unknown") ;
- return 1 ;
-
- ------- mon.c -------
- *** /tmp/da18472 Thu Jul 5 16:57:44 1990
- --- mon.c Thu Jul 5 15:50:52 1990
- ***************
- *** 15,21 ****
- --- 15,25 ----
- */
-
- #include <stdio.h>
- + #ifdef SYSV
- + #include <string.h>
- + #else
- #include <strings.h>
- + #endif /*SYSV*/
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <sys/time.h>
-
- ------- rec.c -------
- *** /tmp/da18475 Thu Jul 5 16:57:45 1990
- --- rec.c Thu Jul 5 15:57:19 1990
- ***************
- *** 15,21 ****
- --- 15,25 ----
- */
-
- #include <stdio.h>
- + #ifdef SYSV
- + #include <string.h>
- + #else
- #include <strings.h>
- + #endif /*SYSV*/
- #include "faces.h"
- #include "extern.h"
-
-
- ------- faces.h -------
- *** /tmp/da18478 Thu Jul 5 16:57:46 1990
- --- faces.h Thu Jul 5 13:20:44 1990
- ***************
- *** 14,19 ****
- --- 14,25 ----
- * reported to me then an attempt will be made to fix them.
- */
-
- + #ifdef DEBUG
- + #define IF_DEBUG(stmt) stmt
- + #else
- + #define IF_DEBUG(stmt)
- + #endif /*DEBUG*/
- +
- #define FCLOSE (void) fclose /* To make lint happy. */
- #define FFLUSH (void) fflush
- #define FGETS (void) fgets
-
- ------- patchlevel.h -------
- *** /tmp/da18482 Thu Jul 5 16:57:47 1990
- --- patchlevel.h Thu Jul 5 12:46:00 1990
- ***************
- *** 14,17 ****
- * reported to me then an attempt will be made to fix them.
- */
-
- ! #define PATCHLEVEL 5
- --- 14,17 ----
- * reported to me then an attempt will be made to fix them.
- */
-
- ! #define PATCHLEVEL 6
-
- ------- README -------
- *** /tmp/da18485 Thu Jul 5 16:57:48 1990
- --- README Thu Jul 5 16:46:35 1990
- ***************
- *** 109,114 ****
- --- 109,115 ----
- INVERT - inverse video.
- NEWSINCDIR - NeWS only: location of the NeWS #include files.
- NEWSLIBDIR - NeWS only: location of the NeWS libraries.
- + NISLOOKUP - uncomment to use Sun NIS (formerly YP) to look for hosts.
- NODOMAINS - uncomment if you don't want full host domain names.
- NOINDEX - uncomment if you don't have the index() function.
- PERIOD - alternate period in seconds before recheck.
- ***************
- *** 115,120 ****
- --- 116,122 ----
- REVORDER - byte reversal for little-endian machines.
- SELTYPE - uncomment for old select(2) calls.
- SPOOLFILE - alternate default spoolfile to monitor.
- + SYSV - uncomment if you are running Unix System V.
- TTEXT - SunView only: uncomment on SunOS v3.x systems.
- UPDATE - alternate mail alias for faces database updating.
- X11INCDIR - X11 only: location of the X11 #include files.
- ***************
- *** 249,255 ****
- James Ashton for the mail header face compression / uncompression code.
-
- Pat Lashley for fixing up the NeWS version; modifying it to use cps, and
- ! improving the quality of the NeWS code.
-
- Chris Maltby for the parsefrom routine used to extract the username and
- hostname from the "From " and "From:"lines. Chris also supplied a shell
- --- 251,258 ----
- James Ashton for the mail header face compression / uncompression code.
-
- Pat Lashley for fixing up the NeWS version; modifying it to use cps, and
- ! improving the quality of the NeWS code. Pat also added the ability to use
- ! the Sun NIS, to look for hosts not found in the machines.tab file.
-
- Chris Maltby for the parsefrom routine used to extract the username and
- hostname from the "From " and "From:"lines. Chris also supplied a shell
- ***************
- *** 282,288 ****
- parsing.
-
- Dave Cohrs for several fixes and enhancements, the addition of X11 bitmap
- ! support, and generally sorting out most of the problems with the X11 version.
-
- Greg Dudek for an alternative version of "on-the-fly" X-Face imaging which
- hasn't been used.
- --- 285,292 ----
- parsing.
-
- Dave Cohrs for several fixes and enhancements, the addition of X11 bitmap
- ! support, and generally sorting out most of the problems with the previous
- ! X11 version.
-
- Greg Dudek for an alternative version of "on-the-fly" X-Face imaging which
- hasn't been used.
- ***************
- *** 289,296 ****
-
- Also thanks to Jeremy Cook, John Machin, Neil Crellin, Mark Andrews, Sjoerd
- Mullender, Cameron Humphries, Rick Gunderson, Rich McAllister, Hakon Lie,
- ! John Fong, Chris Maltby, Darryl K. Ramm, Steve Piette, Tony Landells and
- ! Pat Lashley for various bug reports, fixes and suggestions for improvement.
-
-
- ----------------------------------------------------------------------------
- --- 293,301 ----
-
- Also thanks to Jeremy Cook, John Machin, Neil Crellin, Mark Andrews, Sjoerd
- Mullender, Cameron Humphries, Rick Gunderson, Rich McAllister, Hakon Lie,
- ! John Fong, Chris Maltby, Darryl K. Ramm, Steve Piette, Tony Landells, Pat
- ! Lashley, Dave Glowacki, Chris Steinbroner and Steven M. Miller for various
- ! bug reports, fixes and suggestions for improvement.
-
-
- ----------------------------------------------------------------------------
-
- ------- faces.1 -------
- *** /tmp/da18488 Thu Jul 5 16:57:49 1990
- --- faces.1 Thu Jul 5 12:54:32 1990
- ***************
- *** 94,100 ****
- monitor mail, print queues or users on a system.. It contains graphical
- interfaces for NeWS, SunView, XView and X11. It has five different modes of
- operation:
- ! .LP
- The default (no
- .BR -a ,
- .BR -H ,
- --- 94,100 ----
- monitor mail, print queues or users on a system.. It contains graphical
- interfaces for NeWS, SunView, XView and X11. It has five different modes of
- operation:
- ! .PP
- The default (no
- .BR -a ,
- .BR -H ,
- ***************
- *** 108,114 ****
- or the time the mail message arrived. You can clear this area to the
- background pattern by hitting the Delete key. The icon shows the image
- of the last message to arrive.
- ! .LP
- The second choice
- .RB ( -a )
- is to monitor the whole of a mail file. The open window will
- --- 108,114 ----
- or the time the mail message arrived. You can clear this area to the
- background pattern by hitting the Delete key. The icon shows the image
- of the last message to arrive.
- ! .PP
- The second choice
- .RB ( -a )
- is to monitor the whole of a mail file. The open window will
- ***************
- *** 117,123 ****
- message from that user. The icon will display the image of the last
- message, and a count of the total number of messages in the spool
- file or mail folder.
- ! .LP
- The third option
- .RB ( -P )
- allows this program to monitor a given print queue.
- --- 117,123 ----
- message from that user. The icon will display the image of the last
- message, and a count of the total number of messages in the spool
- file or mail folder.
- ! .PP
- The third option
- .RB ( -P )
- allows this program to monitor a given print queue.
- ***************
- *** 126,138 ****
- number of jobs to be printed. Opening the window will show images of all
- the jobs in the queue. The text on each image can be toggled, choices
- being the owners' name and the size of the job in bytes.
- ! .LP
- With the fourth mode
- .RB ( -H ),
- you can monitor who is logged in a machine.
- For each user, a face image is displayed. Text can be either the username
- or the time they logged on. The iconic form displays the total number of users.
- ! .LP
- Finally
- you can specify a program or shell script to run
- .RB ( -e ).
- --- 126,138 ----
- number of jobs to be printed. Opening the window will show images of all
- the jobs in the queue. The text on each image can be toggled, choices
- being the owners' name and the size of the job in bytes.
- ! .PP
- With the fourth mode
- .RB ( -H ),
- you can monitor who is logged in a machine.
- For each user, a face image is displayed. Text can be either the username
- or the time they logged on. The iconic form displays the total number of users.
- ! .PP
- Finally
- you can specify a program or shell script to run
- .RB ( -e ).
- ***************
- *** 140,146 ****
- from this program will be read by the faces program, and the appropriate faces
- displayed using the information provided. The format of this face information
- is given in the faces manual page.
- ! .LP
- There are special displays for no mail, no faces found, no print jobs,
- no paper in the printer, and no users logged into a machine.
- .SH OPTIONS
- --- 140,146 ----
- from this program will be read by the faces program, and the appropriate faces
- displayed using the information provided. The format of this face information
- is given in the faces manual page.
- ! .PP
- There are special displays for no mail, no faces found, no print jobs,
- no paper in the printer, and no users logged into a machine.
- .SH OPTIONS
- ***************
- *** 290,296 ****
- .I username
- level is a plain file (not a directory) it is assumed to be a
- Blit icon.
- ! .LP
- To access the face for the mail name
- .I machine!uid
- take the result of the first successful open from the following list of files:
- --- 290,296 ----
- .I username
- level is a plain file (not a directory) it is assumed to be a
- Blit icon.
- ! .PP
- To access the face for the mail name
- .I machine!uid
- take the result of the first successful open from the following list of files:
- ***************
- *** 332,338 ****
- .I uucp.
- If the faces directory hierarchy is not found, then a blank face image
- will be used.
- ! .LP
- Faces information is administered by a pair of ASCII files in the faces
- directory that associate related machines and faces. The machine table
- .I machine.tab
- --- 332,338 ----
- .I uucp.
- If the faces directory hierarchy is not found, then a blank face image
- will be used.
- ! .PP
- Faces information is administered by a pair of ASCII files in the faces
- directory that associate related machines and faces. The machine table
- .I machine.tab
- ***************
- *** 354,360 ****
- .I richb
- for the community
- .I sunaus
- ! .LP
- Note that you still need to use
- .I mailtool
- or some other mail reading utility to actually read the mail that this program
- --- 354,360 ----
- .I richb
- for the community
- .I sunaus
- ! .PP
- Note that you still need to use
- .I mailtool
- or some other mail reading utility to actually read the mail that this program
- ***************
- *** 361,367 ****
- monitors;
- .I faces
- simply displays who the mail is from.
- ! .LP
- When new mail arrives,
- .B faces
- will beep and flash appropriately, depending upon the set parameters in
- --- 361,367 ----
- monitors;
- .I faces
- simply displays who the mail is from.
- ! .PP
- When new mail arrives,
- .B faces
- will beep and flash appropriately, depending upon the set parameters in
- ***************
- *** 368,374 ****
- the users
- .I .mailrc
- file.
- ! .LP
- If you are using the NeWS version and creating face images of the
- .I face.ps
- form, then the following points should be noted:
- --- 368,374 ----
- the users
- .I .mailrc
- file.
- ! .PP
- If you are using the NeWS version and creating face images of the
- .I face.ps
- form, then the following points should be noted:
- ***************
- *** 375,381 ****
- All graphics operations should be performed on the unit square; and
- the final image will be translated to a 64 x 64 square image at
- the appropriate position in the faces display.
- ! .LP
- If you are using the
- .B \-e
- option, then the user program or shell script should firstly generate a
- --- 375,381 ----
- All graphics operations should be performed on the unit square; and
- the final image will be translated to a 64 x 64 square image at
- the appropriate position in the faces display.
- ! .PP
- If you are using the
- .B \-e
- option, then the user program or shell script should firstly generate a
- ***************
- *** 385,391 ****
- .RE
- where mm is the size in columns for the faces window and icon, and
- nn is the size in rows. A window will be generated with these dimensions.
- ! .LP
- This record is followed by the face information records, which are again
- in fixed format. As well as providing the username and hostname, there are
- four other fields which can be filled in, which denote what is displayed
- --- 385,391 ----
- .RE
- where mm is the size in columns for the faces window and icon, and
- nn is the size in rows. A window will be generated with these dimensions.
- ! .PP
- This record is followed by the face information records, which are again
- in fixed format. As well as providing the username and hostname, there are
- four other fields which can be filled in, which denote what is displayed
- ***************
- *** 404,410 ****
- icon left 61 10
- icon right 71 10
- .TE
- ! .LP
- Any of these fields may be left blank. There are also four special usernames,
- which will display the appropriate standard icons. These are
- .B "NOMAIL, NOPAPER, NOPRINT "
- --- 404,410 ----
- icon left 61 10
- icon right 71 10
- .TE
- ! .PP
- Any of these fields may be left blank. There are also four special usernames,
- which will display the appropriate standard icons. These are
- .B "NOMAIL, NOPAPER, NOPRINT "
-
- ------- Makefile -------
- *** /tmp/da18491 Thu Jul 5 16:57:51 1990
- --- Makefile Thu Jul 5 16:50:21 1990
- ***************
- *** 72,77 ****
- --- 72,83 ----
- #NEWSINCDIR = -I$(OPENWINHOME)/include
- #NEWSLIBDIR = -L$(OPENWINHOME)/lib
- #------------------------------------------------------------------------
- + # Uncomment the following two lines to use the Sun Network Information
- + # Services (NIS, formerly YP) to look for hosts which do not explicitly
- + # appear in the machines.tab file.
- + #
- + #NISLOOKUP = -DNISLOOKUP
- + #------------------------------------------------------------------------
- # If you don't want faces to use full domain names for extracting face
- # icons, then you should uncomment the NODOMAINS definition below.
- #
- ***************
- *** 109,115 ****
- # appropriately.
- #
- #SPOOLFILE = -DSPOOLFILE=\"/usr/richb/Mail/pending\"
- ! #------------------------------------------------------------------------
- # If you are running SunOS v3.x, then pr_ttext doesn't exist, and
- # you must uncomment this definition.
- #
- --- 115,126 ----
- # appropriately.
- #
- #SPOOLFILE = -DSPOOLFILE=\"/usr/richb/Mail/pending\"
- ! #--------------------------------------------------------------------------
- ! # If you are running on a Unix System V machine, then you should uncomment
- ! # the next definition.
- ! #
- ! #SYSV = -DSYSV
- ! #--------------------------------------------------------------------------
- # If you are running SunOS v3.x, then pr_ttext doesn't exist, and
- # you must uncomment this definition.
- #
- ***************
- *** 150,165 ****
- #
- # Options for submakes
- #
- ! MAKEOPTS = $(MFLAGS) BINDIR=$(BINDIR) LIBDIR=$(LIBDIR) MANDIR=$(MANDIR)
-
- #
- # Compilation flags and standard macro definitions.
- #
- CDEFS = $(BACKGROUND) $(DONTSHOWNO) $(DONTSHOWTIME) \
- $(DONTSHOWUSER) $(CFACEDIR) $(FMONTYPE) $(INVERT) \
- ! $(NEWSINCDIR) $(NODOMAINS) $(NOINDEX) $(PERIOD) \
- ! $(REVORDER) $(SELTYPE) $(SPOOLFILE) $(TTEXT) $(UPDATE) \
- ! $(X11INCDIR) $(XVIEWINCDIR)
- CCOMP = -g
- CFLAGS = $(CCOMP) $(CDEFS)
- #
- --- 161,183 ----
- #
- # Options for submakes
- #
- ! MAKEOPTS = $(MFLAGS) BINDIR=$(BINDIR) LIBDIR=$(LIBDIR) \
- ! MANDIR=$(MANDIR) NOINDEX=$(NOINDEX)
-
- #
- + # Override DEBUG on the command line as `DEBUG=-DDEBUG' to enable various
- + # additional checking diagnostic output options.
- + #
- + DEBUG =
- +
- + #
- # Compilation flags and standard macro definitions.
- #
- CDEFS = $(BACKGROUND) $(DONTSHOWNO) $(DONTSHOWTIME) \
- $(DONTSHOWUSER) $(CFACEDIR) $(FMONTYPE) $(INVERT) \
- ! $(NEWSINCDIR) $(NISLOOKUP) $(NODOMAINS) $(NOINDEX) \
- ! $(PERIOD) $(REVORDER) $(SELTYPE) $(SPOOLFILE) $(SYSV) \
- ! $(TTEXT) $(UPDATE) $(X11INCDIR) $(XVIEWINCDIR) $(DEBUG)
- CCOMP = -g
- CFLAGS = $(CCOMP) $(CDEFS)
- #
-
- ------- x11.c -------
- *** /tmp/da18494 Thu Jul 5 16:57:52 1990
- --- x11.c Thu Jul 5 15:24:04 1990
- ***************
- *** 164,169 ****
- --- 164,170 ----
- int argc ;
- char *argv[] ;
- {
- + char *def_geom ;
- int i, j ;
- unsigned short buf[256] ;
-
- ***************
- *** 184,191 ****
-
- screen = DefaultScreen(dpy) ;
- root = RootWindow(dpy, screen) ;
- ! if (geometry[0] != '\0')
- ! STRCPY(geometry, XGetDefault(dpy, progname, "Geometry")) ;
-
- foregnd = BlackPixel(dpy, screen) ;
- backgnd = WhitePixel(dpy, screen) ;
- --- 185,193 ----
-
- screen = DefaultScreen(dpy) ;
- root = RootWindow(dpy, screen) ;
- ! if (geometry[0] == '\0' &&
- ! (def_geom = XGetDefault(dpy, progname, "Geometry")) != NULL)
- ! STRCPY(geometry, def_geom) ;
-
- foregnd = BlackPixel(dpy, screen) ;
- backgnd = WhitePixel(dpy, screen) ;
-
- ------- TODO -------
- *** /tmp/da18497 Thu Jul 5 16:57:53 1990
- --- TODO Thu Jul 5 15:32:25 1990
- ***************
- *** 57,62 ****
- --- 57,67 ----
- to update the wrong face in the faces database. The only clean solution
- to this, is if faces only recognises X-Face lines in the mail header.
-
- + From Pat Lashley <patl@Sun.COM>
- + The problem with finding an X-Face: entry in an included message can be
- + resolved by a flag which would restrict X-Face: recognition to the header
- + or the first non-blank line of the body.
- +
- 12/ From Pat Lashley <patl@Sun.COM>
- An entry of the form `+domainname=community' in the machines.tab file to
- indicate that if a hostname is found without domain specifier, and it
- ***************
- *** 94,97 ****
-
- 19/ Add an option to disable flashing and beeping when new mail arrives.
-
- ! 20/ Optimise.
- --- 99,127 ----
-
- 19/ Add an option to disable flashing and beeping when new mail arrives.
-
- ! 20/ From Pat Lashley <patl@Sun.COM>
- ! Change window header to show what is being monitored (mail, lp1, users,
- ! etc.)
- !
- ! 21/ From Pat Lashley <patl@Sun.COM>
- ! A mixed-mode version which would use xview for the basic windowing and
- ! property sheets; but use NeWS for the rendering. It is, of course,
- ! dependant upon having the X/NeWS server, but there may be some way to
- ! determine at run-time whether the NeWS operations are available, or
- ! whether to stick to XView/X11 mechanisms.
- !
- ! 22/ From Steven M. Miller <miller@SCTC.COM>
- ! I would like to use -iconic to specify iconic mode for X. This would
- ! require change -i to -I for inverse in get.c and having -i to set iconic=1.
- !
- ! 23/ From Steven M. Miller <miller@SCTC.COM>
- ! Under X, when faces is started up in iconic mode nothing is displayed in
- ! the icon until the icon is clicked on and opened and then closed again.
- !
- ! 24/ From Kee Hinckley <nazgul@alphalpha.com>
- ! Any possibility of changing that header to an RFC1154 (I think that's
- ! the number) conformant form? Namely an encoding field in the
- ! header (presumbably with a new name for the faces format, or using
- ! one of the existing ones (G3Fax uuencode would probably be good)).
- !
- ! 25/ Optimise.
-
- ------- CHANGES -------
- *** /tmp/da18500 Thu Jul 5 16:57:53 1990
- --- CHANGES Thu Jul 5 16:46:04 1990
- ***************
- *** 140,142 ****
- --- 140,183 ----
- The definition for MANDIR in the main Makefile is incorrect.
-
- [Posted to comp.sources.misc]
- +
- + v1.4 - patchlevel 6 - 5th July 1990.
- +
- + * From Tony Landells <ahl@technix.oz.au>
- + Change all the .LP macros in the manual pages to .PP, since .PP is
- + an alternative to .LP is newer versions of the manual pages, while
- + it is the alternative to .P in older versions; but older versions
- + don't have .LP and newer ones don't have .P. Thus .PP seems to be
- + the only universally accepted one.
- +
- + * From Pat Lashley <patl@Sun.COM>
- + make_iconname() is broken with respect to multi-level domains. One
- + symptom is that `unknown' will always come from misc.. The problem
- + is that the for loops are nested backwards.
- +
- + * From Pat Lashley <patl@Sun.COM>
- + Code to impliment simple NIS lookup for hosts not explicitly
- + mentioned in the machines table. Note there is another definition
- + at the front of the Makefile (NISLOOKUP), then should be uncommented
- + to use this feature. The README file has been updated.
- +
- + * From Dave Glowacki <dglo@ads.com>
- + From Steven M. Miller <miller@SCTC.COM>
- + If the geometry has been set with -geometry you don't want to try
- + and get the default. Additionally if no default is set XGetDefault
- + returns NULL which crashes the faces program.
- +
- + * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- + For system V and varients, there is no <strings.h>; it is <string.h>.
- + I've added yet another definition (SYSV) to the Makefile, that
- + should be uncommented, if this is the case for your machine. The
- + README file has been updated.
- +
- + * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- + Making rs2icon fails because my machine has no rasterfile.h
- + include file. The #include <rasterfile.h> has been removed from
- + this file, and the structure definition added to the source file.
- +
- + * From Chris Steinbroner <hesh@lll-crg.llnl.gov>
- + ikon2icon in the filters directory uses index(), so you have to do
- + the NOINDEX define stuff there too.
-
- ------- parsefrom.c -------
- *** /tmp/da18503 Thu Jul 5 16:57:54 1990
- --- parsefrom.c Thu Jul 5 16:52:06 1990
- ***************
- *** 15,21 ****
- --- 15,25 ----
- */
-
- #include <stdio.h>
- + #ifdef SYSV
- + #include <string.h>
- + #else
- #include <strings.h>
- + #endif /*SYSV*/
- #include "faces.h"
-
-
-
- ------- filters/ikon2icon.c -------
- *** /tmp/da18598 Thu Jul 5 17:00:10 1990
- --- filters/ikon2icon.c Thu Jul 5 16:48:44 1990
- ***************
- *** 16,27 ****
-
- #include <stdio.h>
-
- ! #define PATCHLEVEL 0
-
- #define GETS (void) gets /* To make lint happy. */
- #define PRINTF (void) printf
- #define SPRINTF (void) sprintf
- #define SSCANF (void) sscanf
-
- #define BLITHEIGHT 48 /* Maximum number of lines in a blit icon. */
- #define MAXLINE 80 /* Maximum length for character strings. */
- --- 16,31 ----
-
- #include <stdio.h>
-
- ! #define PATCHLEVEL 1
-
- #define GETS (void) gets /* To make lint happy. */
- #define PRINTF (void) printf
- #define SPRINTF (void) sprintf
- #define SSCANF (void) sscanf
- +
- + #ifdef NOINDEX
- + #define index strchr
- + #endif /*NOINDEX*/
-
- #define BLITHEIGHT 48 /* Maximum number of lines in a blit icon. */
- #define MAXLINE 80 /* Maximum length for character strings. */
-
- ------- filters/rs2icon.c -------
- *** /tmp/da18601 Thu Jul 5 17:00:11 1990
- --- filters/rs2icon.c Thu Jul 5 16:27:04 1990
- ***************
- *** 21,30 ****
- */
-
- #include <stdio.h>
- ! #include <rasterfile.h>
- #include <strings.h>
-
- ! #define PATCHLEVEL 0
-
- #define FPRINTF (void) fprintf /* To make lint happy. */
- #define FREAD (void) fread
- --- 21,47 ----
- */
-
- #include <stdio.h>
- ! #ifdef SYSV
- ! #include <string.h>
- ! #else
- #include <strings.h>
- + #endif /*SYSV*/
-
- ! #define PATCHLEVEL 1
- !
- ! /* Taken from: @(#)rasterfile.h 1.11 89/08/21 SMI. */
- !
- ! struct rasterfile {
- ! int ras_magic; /* magic number */
- ! int ras_width; /* width (pixels) of image */
- ! int ras_height; /* height (pixels) of image */
- ! int ras_depth; /* depth (1, 8, or 24 bits) of pixel */
- ! int ras_length; /* length (bytes) of image */
- ! int ras_type; /* type of file; see RT_* below */
- ! int ras_maptype; /* type of colormap; see RMT_* below */
- ! int ras_maplength; /* length (bytes) of following map */
- ! /* color map follows for ras_maplength bytes, followed by image */
- ! };
-
- #define FPRINTF (void) fprintf /* To make lint happy. */
- #define FREAD (void) fread
-
- ------- filters/Makefile -------
- *** /tmp/da18604 Thu Jul 5 17:00:11 1990
- --- filters/Makefile Thu Jul 5 16:45:35 1990
- ***************
- *** 12,25 ****
- # to the comments or the code of this program, but if reported
- # to me then an attempt will be made to fix them.
-
- ! # BINDIR is expected to be overridden by the calling Makefile
-
- BINDIR = /usr/local/bin
-
- ! BINARIES = icon2ikon ikon2icon rs2icon
-
- CC = cc
- ! CFLAGS = -g
-
- all: $(BINARIES)
-
- --- 12,35 ----
- # to the comments or the code of this program, but if reported
- # to me then an attempt will be made to fix them.
-
- ! # BINDIR and NOINDEX are expected to be overridden by the calling Makefile
-
- + #--------------------------------------------------------------------------
- BINDIR = /usr/local/bin
- + #--------------------------------------------------------------------------
- + # Not all machines have the index() string library function. If you
- + # don't have this function then you should uncomment the NOINDEX
- + # definition below.
- + #
- + #NOINDEX = -DNOINDEX
- + #--------------------------------------------------------------------------
-
- ! BINARIES = icon2ikon ikon2icon rs2icon
-
- CC = cc
- ! CDEFS = $(NOINDEX)
- ! CCOMP = -g
- ! CFLAGS = $(CCOMP) $(CDEFS)
-
- all: $(BINARIES)
-
-
- ------- filters/icon2ikon.c -------
- *** /tmp/da18607 Thu Jul 5 17:00:12 1990
- --- filters/icon2ikon.c Thu Jul 5 16:27:20 1990
- ***************
- *** 17,25 ****
- */
-
- #include <stdio.h>
- #include <string.h>
-
- ! #define PATCHLEVEL 0
-
- #define FPRINTF (void) fprintf /* To make lint happy. */
- #define PRINTF (void) printf
- --- 17,29 ----
- */
-
- #include <stdio.h>
- + #ifdef SYSV
- #include <string.h>
- + #else
- + #include <strings.h>
- + #endif /*SYSV*/
-
- ! #define PATCHLEVEL 1
-
- #define FPRINTF (void) fprintf /* To make lint happy. */
- #define PRINTF (void) printf
-
-