1
0
mirror of synced 2026-01-12 00:42:56 +00:00
Interlisp.medley/lispusers/CANVASCONVERTER.TEDIT
2020-11-15 19:22:14 -08:00

13 lines
6.0 KiB
Plaintext
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

en·vÅos CANVASCONVERTER
2
4
1
CANVASCONVERTER
1
4
By: Stephen Knowles (Stephen Knowles:49/89/636/13:Siemens AG)
Partly based on work by:
Matthias Schneider-Hufschmidt (Matthias Schneider-Hufschmidt:ZTISOF:SIEMENS)
Giselbert Schramm (Giselbert Schramm:ZTISOF:SIEMENS)
Uses: BITMAPFNS
This document last edited on (620673493 NIL NIL)
.
INTRODUCTION
This module enables the transfer of bitmaps between the Envos Lisp and Xerox ViewPoint environments. The medium used for the transfer is an NS file server (i.e. a file drawer which can be accessed by both environments). The possibility of transferring Lisp bitmaps into the ViewPoint environment is particularly useful for documenting Lisp applications.
MODULE EXPLANATIONS
There are essentially two major functions:
(IL:WRITECANVAS BITMAP FILE) [Function]
This function writes the BITMAP on to FILE and makes FILE of type ViewPoint Canvas, whereby FILE must be on an NS file server.
(IL:FETCHCANVAS FILE) [Function]
This function reads FILE into a Lisp bitmap, whereby FILE must be on an NS file server.
Additionally there are two auxiliary functions to aid in the use of the above two functions.
(IL:SNAPBM) [Function]
and
(IL:CANVAS-FROM-WINDOW WINDOW FILE) [Function]
EXAMPLES
All examples must be typed into an INTERLISP exec.
To write a canvas of a Lisp screen region:
(WRITECANVAS (SNAPBM)
'{NSFileServer:Domain:Organization}<FileDrawer>Folder>TESTFILE)
To write a canvas of a Lisp window:
(CANVAS-FROM-WINDOW (WHICHW)
'{NSFileServer:Domain:Organization}<FileDrawer>Folder>TESTFILE)
To read a canvas into a Lisp bitmap:
(SETQ X (OPENSTREAM
'{NSFileServer:Domain:Organization}<FileDrawer>Folder>TESTCANVAS 'INPUT))
(EDITBM (SETQ LISPBITMAP (FETCHCANVAS X)))
(CLOSEF X)
CAVEAT
When fetching a canvas, there is a 50-50 chance that the Lisp bitmap will be O.K. It could, however, come out distorted (this is due to the differing ways in which ViewPoint and Lisp handle bitmaps, Lisp uses 16 complement, ViewPoint 32 complement - or something like that). If this should be the case, simply increase the canvas width in ViewPoint by 5 millimeters (approx. 16 pixels) and repeat the fetching process.
Unfortunately in the Lyric version if one repeatedly wrote a canvas with the same name, the file server somehow got mixed up and set the file-info of the folder above the canvas into ºtype = canvasº! One could put this right with the (SETFILEINFO...) function in Lisp, although under normal circumstances one does not write out a canvas repeatedly with the same name any way. I have been unable to test the behaviour in MEDLEY.
Compatibility has only been tested up to ViewPoint 1.1.(LIST ((PAGE NIL (PAPERSIZE Letter FOLIOINFO (ARABIC "" "") STARTINGPAGE# 34) (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 (ARABIC "" "")) (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 Letter FOLIOINFO (ARABIC "" "") STARTINGPAGE# NIL) (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 (ARABIC "" "")) (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 Letter FOLIOINFO (ARABIC "" "") STARTINGPAGE# NIL) (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 (ARABIC "" "")) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))))) 3ÈÈT3ÈÈT2ÈÈ2ÈÈ,È,È,ŠŠ8,ŠŠ8HÈÈ PAGEHEADING RUNNINGHEAD
CLASSICCLASSICCLASSICTERMINAL
 HELVETICA
MODERN
MODERN
MODERN MODERN
MODERN 
   HRULE.GETFNMODERN
  HRULE.GETFNMODERN
  HRULE.GETFNMODERN
  HRULE.GETFNMODERN  HRULE.GETFNMODERN ?  N 6     DOCOBJ-TIMESTAMP-GETFN   b ,      
$        ]        3 , @ $ @ % J+ £ ¬ 7
^ƒzº