(DEFINE-FILE-INFO READTABLE "INTERLISP" PACKAGE "INTERLISP") (FILECREATED " 3-Aug-88 16:16:39" {ERINYES}<LISPUSERS>LYRIC>LISPNERD.;3 10439 changes to%: (VARS LISPNERDCOMS) previous date%: "25-Jan-88 11:18:03" {ERINYES}<LISPUSERS>LYRIC>LISPNERD.;2) (* " Copyright (c) 1987, 1988 by Xerox Corporation. All rights reserved. ") (PRETTYCOMPRINT LISPNERDCOMS) (RPAQQ LISPNERDCOMS ((COMS * LISPNERDDEPENDENCIES) (* must come before any FILES) (FILES ANALYZER DINFO HELPSYS (FROM {QV}<DICTSERVER>LISP>) DICTCLIENT) (FNS LISPNERD.INIT IRMNERD.PRINTSEARCH) (INITVARS IRMDICT IRMNERD.LASTSEARCH IRMNERD.LASTREQUEST (IRMNERD.MAXWORDS 50)) (GLOBALVARS IRMDICT IRMNERD.LASTSEARCH IRMNERD.LASTREQUEST IRMNERD.MAXWORDS) (FNS IRMDICT.PRINTENTRY) (P (LISPNERD.INIT)))) (RPAQQ LISPNERDDEPENDENCIES [(* * code to make sure that the right versions of everything are loaded. The P must be executed before any FILES commands.) [E (PUTPROP 'LISPNERD 'DEPENDENCIES (for FILE in (FILECOMSLST 'LISPNERD 'FILES) collect (CONS FILE (CAAR (GETPROP FILE 'FILEDATES] (PROP DEPENDENCIES LISPNERD) (P (for FILE FILEDATE in (GETPROP 'LISPNERD 'DEPENDENCIES) do [SETQ FILEDATE (CAAR (GETPROP (CAR FILE) 'FILEDATES] (COND ([AND FILEDATE (CDR FILE) (ILESSP (IDATE FILEDATE) (IDATE (CDR FILE] (* clear FILEDATES to force FILESLOAD to reload the file.) (PUTPROP (CAR FILE) 'FILEDATES NIL]) (* * code to make sure that the right versions of everything are loaded. The P must be executed before any FILES commands.) (PUTPROPS LISPNERD DEPENDENCIES ((ANALYZER . " 3-Jun-88 17:03:38") (DINFO . " 1-Oct-87 10:11:04") (HELPSYS . " 1-Oct-87 13:40:16") (DICTCLIENT . " 8-Oct-87 15:15:08"))) [for FILE FILEDATE in (GETPROP 'LISPNERD 'DEPENDENCIES) do [SETQ FILEDATE (CAAR (GETPROP (CAR FILE) 'FILEDATES] (COND ([AND FILEDATE (CDR FILE) (ILESSP (IDATE FILEDATE) (IDATE (CDR FILE] (* clear FILEDATES to force FILESLOAD to reload the file.) (PUTPROP (CAR FILE) 'FILEDATES NIL] (* must come before any FILES) (FILESLOAD ANALYZER DINFO HELPSYS (FROM {QV}<DICTSERVER>LISP>) DICTCLIENT) (DEFINEQ (LISPNERD.INIT [LAMBDA NIL (* jtm%: "18-Nov-87 14:36") (COND ((NULL IRMDICT) [Dict.Establish (SETQ IRMDICT (create Dict dictName ← 'IRMDict printEntryFn ← (FUNCTION IRMDICT.PRINTENTRY] (PUTASSOC 'Search% IRM '((IRMNERD.PRINTSEARCH) "Searches the Interlisp Reference Manual for entries given a list of keywords." ) BackgroundMenuCommands) (SETQ BackgroundMenu NIL]) (IRMNERD.PRINTSEARCH [LAMBDA (SYNONYMCLASSES) (* jtm%: " 7-Apr-87 12:33") (PROG (VENNDIAGRAM SELECTION MENUITEMS (MINWORD 0) (MAXWORD IRMNERD.MAXWORDS)) [COND ((NULL SYNONYMCLASSES) (CLRPROMPT) (PROMPTPRINT (CHARACTER (CHARCODE CR))) (SETQ SYNONYMCLASSES (PROMPTFORWORD "keywords to search on:" IRMNERD.LASTREQUEST NIL PROMPTWINDOW NIL NIL (CHARCODE EOL ESCAPE LF))) (COND ((NULL SYNONYMCLASSES) (PROMPTPRINT "Aborted") (RETURN)) (T (CLRPROMPT))) (COND ((NOT (STREQUAL SYNONYMCLASSES IRMNERD.LASTREQUEST)) (SETQ IRMNERD.LASTREQUEST SYNONYMCLASSES) (SETQ IRMNERD.LASTSEARCH NIL] [do [SETQ VENNDIAGRAM (COND ((AND IRMNERD.LASTSEARCH (EQ MINWORD 0)) IRMNERD.LASTSEARCH) (T (PROMPTPRINT " Searching . . . ") (DICTCLIENT.SEARCHFORWORD SYNONYMCLASSES 2 MINWORD MAXWORD 'IRMNerd] (COND ((EQ MINWORD 0) (* cache the results in case the use calls again.) (SETQ IRMNERD.LASTSEARCH VENNDIAGRAM))) [COND ((NULL VENNDIAGRAM) (PROMPTPRINT "Sorry, no results.") (FLASHWINDOW PROMPTWINDOW) (RETURN)) ((NULL (CDR VENNDIAGRAM)) (SETQ MENUITEMS (CADAR VENNDIAGRAM))) (T (SETQ MENUITEMS (for SET in VENNDIAGRAM collect (LIST [CONCATLIST (for ELEMENT on (CAR SET) collect (COND ((CDR ELEMENT) (CONCAT (CAR ELEMENT) " ")) (T (CAR ELEMENT] (LIST 'QUOTE (CAR SET)) NIL (CONS 'SUBITEMS (CADR SET] (CLRPROMPT) (SETQ SELECTION (MENU (create MENU TITLE ← "IRM Entries" ITEMS ← MENUITEMS CENTERFLG ← T))) (COND ((NULL SELECTION) (PROMPTPRINT " No selection made.") (RETURN)) ((LISTP SELECTION) [for TAIL CLASSNAME on SELECTION do (COND ((EQ (NTHCHARCODE (CAR TAIL) -1) (CHARCODE +)) (SETQ CLASSNAME (SUBSTRING (CAR TAIL) 1 -2)) (RPLACA TAIL (for CLASS in SYNONYMCLASSES thereis (STREQUAL (CAR CLASS) CLASSNAME] (SETQ SYNONYMCLASSES SELECTION) (PROMPTPRINT "Seaching for: " SYNONYMCLASSES) (SETQ MINWORD 0) (SETQ MAXWORD IRMNERD.MAXWORDS)) ((AND (EQ 1 (STRPOS ". . .+" SELECTION)) (STRPOS "more" SELECTION)) (* the user asked for the next chunk.) (SETQ MINWORD (ADD1 MAXWORD)) (SETQ MAXWORD (IPLUS MAXWORD IRMNERD.MAXWORDS))) ((EQ 1 (STRPOS "No more" SELECTION)) (RETURN)) (T (PROMPTPRINT " Fetching definition . . . ") (IRMDICT.PRINTENTRY NIL SELECTION) (CLRPROMPT) (RETURN] (RETURN T]) ) (RPAQ? IRMDICT NIL) (RPAQ? IRMNERD.LASTSEARCH NIL) (RPAQ? IRMNERD.LASTREQUEST NIL) (RPAQ? IRMNERD.MAXWORDS 50) (DECLARE%: DOEVAL@COMPILE DONTCOPY (GLOBALVARS IRMDICT IRMNERD.LASTSEARCH IRMNERD.LASTREQUEST IRMNERD.MAXWORDS) ) (DEFINEQ (IRMDICT.PRINTENTRY [LAMBDA (DICT LEMMA) (* ; "Edited 25-Jan-88 11:10 by jtm:") (LET (FIRSTCHAR SECTION# GRAPH NODE) (SETQ FIRSTCHAR (NTHCHAR LEMMA 1)) [COND ((NUMBERP FIRSTCHAR) [SETQ SECTION# (SUBSTRING LEMMA 1 (SUB1 (OR (STRPOS " " LEMMA) 0] [COND ((EQ (NTHCHARCODE SECTION# -1) (CHARCODE %.)) (* sometimes there is a trailing period.) (SETQ SECTION# (SUBSTRING SECTION# 1 -2] [for I from 1 to (NCHARS SECTION#) do (COND ((EQ (NTHCHARCODE SECTION# I) (CHARCODE %.)) (* DINFO uses dashes instead of periods) (RPLCHARCODE SECTION# I (CHARCODE -] (SETQ SECTION# (MKATOM SECTION#)) (SETQ GRAPH (GETWINDOWUSERPROP DINFOW 'CURRENT.GRAPH)) [COND ((NULL GRAPH) (DINFO.INIT) (SETQ GRAPH (GETWINDOWUSERPROP DINFOW 'CURRENT.GRAPH] (SETQ NODE (FASSOC SECTION# (fetch (DINFOGRAPH NODELST) of GRAPH))) (AND NODE (DINFO.UPDATE NODE))) (T (IRM.SMART.LOOKUP (SUBSTRING LEMMA (COND ((EQ FIRSTCHAR '%() 2) (T 1)) (SUB1 (OR (STRPOS " " LEMMA) 0] T]) ) (LISPNERD.INIT) (PUTPROPS LISPNERD COPYRIGHT ("Xerox Corporation" 1987 1988)) (DECLARE%: DONTCOPY (FILEMAP (NIL (2875 8096 (LISPNERD.INIT 2885 . 3532) (IRMNERD.PRINTSEARCH 3534 . 8094)) (8344 10333 ( IRMDICT.PRINTENTRY 8354 . 10331))))) STOP