XEROX DINFO 2 4 1 DINFO 1 4 By: Doug Cutting (Cutting.PA@Xerox.COM) Uses: GRAPHER, TEDIT This document last edited on October 7, 1987. INTRODUCTION DInfo is a system for browsing graph structured documentation. Graphs for the Interlisp-D Reference Manual and the Xerox Quintus Prolog Manual are available, as are tools for creating and editing new graphs. USER INTERFACE Selecting DInfo from the background menu will pop up a menu listing the available graphs (see DINFO.GRAPHS below). Selecting one of these items will bring up a browser on that graph. Most interaction with DInfo is done through menus at the top of each graph browser which look like this: _џџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўРРРРРРРРРРРРРРРРџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўРРРРФƒјрЦ€ХсбФ"8€ тЯЯ<№ст8Ф’2$"D€AP‚P‘ DФ’р|€Aђƒт‘ 8ФR@€‚‘ Ф22 D‚‘ DФсбФŽ8ƒјт №ст8РРРРРРЯР0У0OЦ РУ>0H& УГ0H%УГ0H%˜€УГOФЄ€УГ0H$Є€У>0H$D˜€џџџџџџџџџџџџ€Р0H$D€Р0€Р0№€РР€РУЯ€€РЦlР€РЦlР€Я€ЦlР€ЬР†Ш€> ЦlР€ЬЮ>yѓц€! УЯ€€ЬУ6Э™†Иqk‡! !#€ €Ь0Э™†„H ! ! @€ЬАy˜ц„‰H ! ‘!$@€РЦ„qG №Я#€€€Р Р€€Р Ю>yѓр€Р У6Э™€€Р0§™€€Р 0С™€€РР 0Э™€€Я€РР Аy˜р€ЬРРр€Ьп<ЦЯ3<Р€ЬлfЦйГdРЯ<№стZ\:€Я˜~lйГpРP‘ ‘"jbF€Ь`lйГт‘ Š>BBB€Ьf8йГLР‘  Š BBB№€Ь<8ЯxР‘ „"BBF˜€Р №стЧDBB:›ч˜йцg€€РB›lил6l€€Р<ѓЭ›6n€Рƒ ›6c€€Рƒ Ч6i€€Рƒ‡уя€Р€Ю00€Я0 0€€№€Я3Ьп0€@џџџџџџџџџџџџ€ЭЖgŒ0€qФ%У gžxpёџџџџџџџџџџџџ€ЭЗу 0€‰$&$A ЈH„‰ "џџџў9џџџџџџџ€Ьі €јЃф$'СёH„ џџџўџўџџџџ€ЬіgŒ0€€Ђ$$H„ џџџў†dџџџџ€ЬsЬЧ0€ˆB$D$AH„‰ "џџџўI3џџџџ€РќpAФ„#†xpёџџџўIžџџџџ€Рџџџўa?žџџџџ€Рџџџўa3џџџџ€Рџџџўq†gџџџџ€Рџџџџџџџџџџџџ€Рџџџџ€џџўџџџџџџџџџџџџ€Рџџџџ€џџў`џџџџџџџџџџџџ€РџџЯ€p?џўc`€ЧТ€чџџЯ€p џџЮc€Ф €ќрС€ѓЯ™€ №Ь‚cgОyі0и`€Ф8ИŽ"@ФžfL€іlй€ цaЮl˜ЭЖ0 `€ФDФ‘"@фјfL€Зьй€ рsЮcnЭƒ` ур€Ф8„‡фђfL€Ж й€ чѓЮcc˜Э@›6`€Ф„™ФђfL€Жlй€ цaЮci˜ЭР 6`€Ф"DФ‘$ј Ь€3ЬЯ€ №Ьтcoy€€ 6`€ЧТ8ИŽˆ@џџчџ€џџў€ 6`€Р€@џџчџ€џџў 3р€Р€0џџчџ€џџў€Р€Р€Р€Р€Яиf0€Р€Ьf0€Р€Ьуц0<Ь36lйяfݘўќpюџ‡џџџџџџџџџџџџџџџџџџџџџџџџ0Ьѓ6oйЛ~ݘўўїdџЛпўџџџџџџџџџџџџџџџџџџџџџџџџ0ЭГ6lЛ`ݘўўїdџЛоœ<џџџџџџџџџџџџџџџџџџџџџџ0<ЭГ6lйЛfݘўў№ъџЛоnћПџџџџџџџџџџџџџџџџџџџџџџ?fјћ3ч“<ЬјўўѕъџЛоюћПџџџџџџџџџџџџџџџџџџџџџџРўўіъџЛоюћПџџџџџџџџџџџџџџџџџџџџџџРўўїjџЛоюћПџџџџџџџџџџџџџџџџџџџџџџРўќwnџ‡Žюќџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџўџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџў The Expanded Menu may be closed independently of the graph browser, and re-opened by selecting Expanded Menu from the title bar menu. Except for this command, the commands in the title bar menu are identical to their counterparts in the Expanded Menu, so only the latter commands are documented. Next to Node:, Top!, Parent!, Previous!, and Next! are printed the names of the node currently being visited, the name of the top node in the graph, the name of the node previous to the current node, and the name of the node next to the previous node, respectively. Top!, Parent!, Previous!, and Next! are also commands as follows: Top! [DInfo Menu Command] Visits the top node in the graph. Parent! [DInfo Menu Command] Visits the parent of the current node. Previous! [DInfo Menu Command] Visits the node previous to the current node. Next! [DInfo Menu Command] Visits the node following the current node. Previous! and Next! thus provide sequential access to the graph. The Display: toggles control what will be displayed when a node is visited: Graph [DInfo Menu Toggle] toggles display of a Grapher display of the graph local to the current node. Selecting a node in this display will visit the corresponding node in the graph. Menu [DInfo Menu Toggle] Toggles display of a menu of subnodes of the current node. If the current node has no subnodes no menu will be displayed. Selecting an item in the subnode Menu will visit that node in the graph. Text [DInfo Menu Toggle] Toggles display of the text of the current node. Turning this off will speed up the visiting of nodes considerably, useful when searching for a particular node. History [DInfo Menu Toggle] Toggles display of a menu containing the history of nodes visited. Selecting an item from this menu will revisit that node. Lookup! [DInfo Menu Command] If selected with the left mouse button prompts for a term and then calls the LOOKUPFN of the graph with it. Using the middle button will re-call the LOOKUPFN with whatever was used previously. This is intended for the lookup of terms in a graph-dependent index. In the case of the Interlisp-D Reference Manual DInfo Graph, Lookup! will lookup a term in the index of the IRM, and then visit the node containing the reference to this term. (DINFO GRAPH.OR.FILE WINDOW.OR.REGIONџџ я% я%џ) [Function] Starts a DInfo browser on GRAPH.OR.FILE in WINDOW.OR.REGION. If GRAPH.OR.FILE is NIL, an empty graph will be created. If WINDOW.OR.REGION is NIL, the user will be prompted for a window or region. GLOBAL VARIABLES DINFOMODES [Variable] Determines which of the toggles will be selected when DInfo is initially started; it should be a list with recognized members being GRAPH, MENU, TEXT, and HISTORY. Default is (GRAPH TEXT). DINFO.HISTORY.LENGTH [Variable] Determines the maximum length of DInfo's history. Default is 20. DINFO.GRAPHS [Variable] Determines the contents of the menu raised by selecting DInfo from the background menu. Should be a menu-items style list where when the CADR of an item is evaluated it returns either a Dinfo Graph (a DINFOGRAPH record) or the name of a file containing a DInfo Graph (i.e, something suitable for passing to DInfo as the GRAPH.OR.FILE arguement). INTERNALS The following information is included for the programmer interested in adding alternate graphs to DInfo. DINFONODE [Record] Contains the following fields: ID Unique identifier for node in graph, ala GRAPHNODE field NODEID. Note that EQ is used for checking identity of nodes. LABEL The print name of a node. Analagous to the GRAPHNODE field NODELABEL. FILE The file containing the documentation for this node. Should not generally include HOST and DIRECTORY fields as DInfo will default these (assuming all documentation files are on one directory, see below). FROMBYTE Byte number in FILE where the documentation for this node begins. TOBYTE Byte number in FILE where the documentation for this node ends. DInfo uses OPENTEXTSTREAM to display its files, and thus any TEdit file can be included. Note that if a file has any formatting (image objects in particular), the byte number of a character in a file is not necessarily the same as the TEdit character number of that character. PARENT The ID field of the node parent to this node. CHILDREN A list of the ID's of the subnodes of this node. NEXTNODE The ID of the next node in the graph. PREVIOUSNODE The ID of the node previous to this node in the graph. USERDATA Unused. Note that there is no special access function for this field as, for example, WINDOWPROP is for the USERDATA field of a WINDOW. This field is left open for use by implementors for whatever they see fit. DINFOGRAPH [Data Type] Contains the following fields of interest to the implementor: NAME The name of the graph. Note that when DInfo reads a graph from a file (with DINFO.READ.GRAPH) this field is set to the NAME field of the file name the graph is read from. NODELST The list of nodes in the graph. Each node should be a DINFONODE record. TOPNODEID The ID field of the root, or top node of the graph. WINDOW The main window of the graph browser. CURRENTNODE Used by DInfo to keep track of where in the graph it is. DEFAULTHOST Used if no host is specified in the FILE field of a node. DEFAULTDEVICE Used if no device is specified in the FILE field of a node. DEFAULTDIR Used if no directory is specified in the FILE field of a node. Note that DEFAULTHOST, DEFAULTDEVICE and DEFAULTDIR are set when a DINFOGRAPH is read from a file (by DINFO.READ.GRAPH) to the host, device and directory of that file. TEXTPROPS Will be passed as the PROPS argument to OPENTEXTSTREAM when the file for a node in the graph is displayed. This feature can be to used to fake some formatting . LOOKUPFN Will be called when the user selects Lookup! from DInfo's Expanded Menu with two arguments: The string to look up, and the current DInfo graph. MENUFN Called when the middle mouse is depressed in the title bar of a graph's window . If not specified, DINFO.DEFAULT.MENU will be used. Passed one argument of the current DInfo graph. DINFO.EDIT.MENU is a MENUFN that allows editing of DInfo graphs. Selecting >>Empty Graph<< from the menu raised by selecting DInfo from the Background Menu will start DInfo on a an empty graph with this MENUFN. FREEMENUITEMS DInfo's Expanded Menu is implemented as a FreeMenu. This property holds a list of FreeMenu item descriptions suitable for passing to FREEMENU (see FreeMenu documentation). This list will be appended onto the bottom row of buttons (Find! and Lookup!) whenever a FreeMenu is created for this graph. USERDATA Accessed by the macro DINFOGRAPHPROP. See below. (DINFOGRAPHPROP GRAPH PROP VALUE) [Macro] If VALUE is not specified, will return the PROP of GRAPH. PROP can be either a real DINFOGRAPH field or something in the USERDATA field. If VALUE is specified it will be put in GRAPH at PROP. Note that in this case it will return the new value stored in, not the previous value, as many other Interlisp-D access functions do. (DINFO.UPDATE GRAPH NODE SEL) [Function] Will visit NODE in GRAPH. NODE, if specified, should be a DINFONODE record which is in the NODELST of GRAPH. SEL is used by DInfo's Interlisp-D Reference Manual lookup facility, and should be useful in implementing other lookup facilities. SEL determines what in the TEXT of this node will be selected. SEL should be a string or a list of the format (NAME X) where NAME is the name of the selection, X is the character number in the text of NODE to be scrolled to. If SEL is a string, the string will be searched for in the text of NODE and selected. This is useful for the lookup of terms. (DINFOGRAPH WINDOW) [Function] Return the DINFOGRAPH associated with window. Note that the pointer from the window to the graph is destroyed when the window is closed to remove circularity. For this reason it is better to keep a handle on the DINFOGRAPH and use (DINFOGRAPHPROP 'WINDOW) when you need the WINDOW. (DINFO.READ.GRAPH FILE QUIETFLG) [Function] Reads a file written by DINFO.WRITE.GRAPH, and returns the DINFOGRAPH contained therein. If QUIETFLG is non-NIL, nothing will be printed out while reading. (DINFO.WRITE.GRAPH GRAPH FILE) [Function] Writes GRAPH to FILE such that it can be read by DINFO.READ.GRAPH. (DINFO.READ.KOTO.GRAPH GRAPH FILE] [Function] Reads a file written by Koto DINFO.WRITE.GRAPH and returns a Lyric DINFOGRAPH. Thus: (DINFO.WRITE.GRAPH (DINFO.READ.KOTO.GRAPH T) ) will convert the Koto format DINFOGRAPH in to a Lyric format DINFOGRAPH in . (LIST ((PAGE NIL (PAPERSIZE LETTER STARTINGPAGE# 56) (0 0 612 792) ((FOLIO NIL (PARALOOKS (QUAD CENTERED) CHARLOOKS (SUPERSCRIPT 0 INVISIBLE OFF SELECTPOINT OFF PROTECTED OFF SIZE 10 FAMILY MODERN OVERLINE OFF STRIKEOUT OFF UNDERLINE OFF EXPANSION REGULAR SLOPE REGULAR WEIGHT MEDIUM INVERTED OFF USERINFO NIL STYLE NIL) FORMATINFO NIL) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))) (PAGE NIL (PAPERSIZE NIL . LETTER) (0 0 612 792) ((FOLIO NIL (PARALOOKS (QUAD CENTERED) CHARLOOKS (SUPERSCRIPT 0 INVISIBLE OFF SELECTPOINT OFF PROTECTED OFF SIZE 10 FAMILY MODERN OVERLINE OFF STRIKEOUT OFF UNDERLINE OFF EXPANSION REGULAR SLOPE REGULAR WEIGHT MEDIUM INVERTED OFF USERINFO NIL STYLE NIL) FORMATINFO NIL) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))) (PAGE NIL (PAPERSIZE NIL . LETTER) (0 0 612 792) ((FOLIO NIL (PARALOOKS (QUAD CENTERED) CHARLOOKS (SUPERSCRIPT 0 INVISIBLE OFF SELECTPOINT OFF PROTECTED OFF SIZE 10 FAMILY MODERN OVERLINE OFF STRIKEOUT OFF UNDERLINE OFF EXPANSION REGULAR SLOPE REGULAR WEIGHT MEDIUM INVERTED OFF USERINFO NIL STYLE NIL) FORMATINFO NIL) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))))).ШШ(Ш.Ш Ш.Ш Ш(Ш(ŠŠ8(ŠŠ8DШШ PAGEHEADING RUNNINGHEADMODERNTERMINAL MODERN MODERN MODERN MODERNMODERN LOGO HRULE.GETFNMODERN  HRULE.GETFNMODERN  HRULE.GETFNMODERN  HRULE.GETFNMODERN  HRULE.GETFNMODERN )- O B"Ь BMOBJ.GETFN3MODERN _ О к "' ., .L ХЂ} ШР!B\ i{NгMI6;0Eп>ВR?.FHLKЈ­š•ј0< э S  @R>-(” *    C  WB+!=9zК