Macrosal(ID:7961/)

Interactive graphics system 


for Macro + SAL, SAL being the target language for LISP

Macro system for lisp to extend it to interactive visual operation after the fashion of SKETHPAD on the PDP-6

Graphical components were forerunner of the SML (also written by Martin)

Required a sepcial secondary storage block (because of LISP garbage collection)


Related languages
LISP 1.5 => Macrosal   Extension of
SAL => Macrosal   Targetting
Sketchpad => Macrosal   Incorporated some features of
Macrosal => SML   Evolution of

References:
  • Martin, William A. "A Version of LISP for the PDP-6" view details Abstract: LISP input-output has been extended to include a dataphone and the Type 640 Oscilloscope with character generator and light pen. A macro language for describing pictures has been embedded in LISP. This system makes possible the coupling of pictorial displays with problems conveniently programmed in LISP, as well as the study of recursive pictures. The choice of concepts for a picture language and tradeoffs involved in its implementation are discussed.
    Extract: A System for Display Language Construction
    A System for Display Language Construction
    The system provides a language macrosal for the generation of picture parts called objects. An object can be any combination of points, lines, and characters. An object is generated by calling the function macrosal [NAME; DESCRIPTION] described in the second section. The most common way to describe an object is to establish a set point. The set point established is utilizing PARAMETER, LOCY, and LOCX statements. The exact format of these statements is discussed below. An object description is terminated with a STOP statement. If NAME is T, the current description will be appended to the description of the last object generated. The first example, - disp, generates a large object in this manner.
    The user communicates with a display through a light pen. As the light pen sweeps across the screen, its trajectory can be used in many different ways. For example, it may be used to determine a point, a set of points, or a line. Or if a subpart of the display has been defined as an object, the trajectory may be simply interpreted as a pointer to this object or a point on the object. The LISP functions embedded in the display language facilitate acquiring the data needed to make these different level s of interpretation.
    One problem in utilizing the light pen is to determine when it is near the screen and not just being moved into place. This is solved by using the width of the field of view of the pen as measured by a tracking cross. This width decreases as the pen approaches the screen, and a center dot is displayed whenever the field of view is less than a specific limit. This pen distance is available to LISP.
    The approach of the pen to an object is considered significant. Just how close the pen must come before being noticed is a program variable. Its most recent position within this distance is recorded; in addition, so are the last five such positions, each at least a prescribed distance from the preceding one. This represents a crude way of gradually forgetting the details of the past. It is also possible to get the current coordinates of the pen; obtain a list of all objects currently seen by the pen; to report when the pen sees an object with a name other than a given name; or to require an object to move with the pen.
    The example function sketch is a LISP function using several of these features. The function uses a subroutine to display five different light buttons. If the light pen is held near one of these buttons, the tracking cross will be centered about the point where the pen is seen. The program interprets pointing at these buttons to mean:
    1. Draw a line.
    2. Move a line.
    3. Delete a line.
    4. Suppress the cross.
    5. Return control to the Teletype.
    To draw lines touch the first button; a new line will then be drawn whenever the pen leaves the screen and then returns. This process is terminated whenever the pen returns near one of the light buttons. Additional LISP functions could be written to expand sketch into a program similar to SKETCH PAD.
    Often one wants to communicate to the display certain basic forms which are to be used in constructing larger units. These inputs might be a set of letters which are to be parsed into a sentence, or they might be a set of circuit elements or music symbols. In SKETCH PAD this is done by indicating the type of form and then moving the light pen so that the parameters of the form, the end points of a line segment for instance, can be abstracted from the trajectory . Alternatively, one could abstract both the type and the parameters from the trajectory. The example program argus uses a method (developed by Teitelman) which enables the user to teach the machine to replace a single line by a known form. A line is a single movement (however complex) on the surface of the display without lifting the pen. The LISP data structure is convenient for storing properties of the forms to be recognized.
    The parsing of very large displayed expressions, such as LISP S-expressions for example, can be difficult for people. Furthermore, there may be alternative parsings. People can be aided by intensifying, upon request, grammatical subexpressions or subobjects containing referenced segments or by providing additional displays meaningfully related to the first display. These might be rotated views of an object or shaded objects. Further development of the system is needed in this area.
    It is the task of the programmer to organize a program and data base in such a way that the most needed inputs to a machine will have short representations and the most needed computations will be efficient. The combinatorial aspects are such that this must be done through a series of levels of concepts. An important point is that it is not possible to complete an entire level at a time. The most useful concepts at a given level only become clear with the exploration of higher levels. The exploration of higher levels without intermediate concepts is, however, almost impossibly tedious. It is important in an experimental situation to have a system where one can make changes to any desired depth and provide for the irregular growth and reorganization of the data base.
    In the present display system, experimentation will probably indicate that new statements for macrosal are needed or that certain objects occur so often that more programming effort could well be spent in generating them efficiently. To provide for these possibilities macrosal has been programmed as a syntactic extension of the Scope Assembly Language, SAL. -SAL is a LISP function which creates objects from lists of octal numbers. It is described in detail under Implementation. Provision has also been made for the addition of machine language subroutines which alter the objects as they are displayed. Furthermore, the system is organized so that no statements need be made about features of the display language which are not needed. By embedding these display facilities in LISP, one makes available a wealth of mechanisms which have proved useful in the analysis and generation of language and in the development of systems which can be increased incrementally in complexity .
          in DECUS Spring Conference 1965 view details