home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 11 / 11.iso / m / m110 / 4.ddi / GRPCT3.EXE / README.DOC < prev    next >
Encoding:
Text File  |  1990-02-12  |  12.8 KB  |  304 lines

  1.  
  2.                  GRASP 3.5 Readme File - February 12, 1990
  3.  
  4. This file contains three sections:
  5.  
  6.     New features in Grasp 3.5
  7.     Updating applications from Grasp 3.1
  8.     Additions to the manual
  9.  
  10. There are two additional Readme files, for Inset and for the High-Level
  11. Language examples.  Inset's Readme is in the INSET directory.  The HLL
  12. Readme in is the HLL directory.
  13.  
  14.  
  15. --------------------------------------------------------------------------
  16.  
  17.  
  18. New features in Grasp 3.5
  19.  
  20. Grasp now sports 102 commands, greatly improved performance, and many new
  21. features which give Grasp all the capabilities of other third-generation
  22. languages like C and Pascal.  Here are some of the highlights:
  23.  
  24. Grasp
  25.  
  26.     Video modes
  27.  
  28.     Grasp now supports most of the enhanced VGA modes, including 16-color
  29.     1024x768 and 256-color 800x600.  As always, the modes available to you
  30.     depend on your video card.  Page 6-4 in the Grasp manual lists all of
  31.     the modes.
  32.  
  33.     Differential animation
  34.  
  35.     The utility GDFF creates differential animation files which Grasp can
  36.     play back.  This technique saves the changes from one frame to another
  37.     in a sequence of images, resulting in much smaller and faster
  38.     animations.  See page 2-13 for an introduction to the concept.
  39.  
  40.     DOS commands, CDs, and other devices
  41.  
  42.     Grasp now has full multimedia capability.  The INT command calls
  43.     interrupts, which allows Grasp programs to control CD players and
  44.     other devices and to issue DOS commands such as Make Directory.  See
  45.     the files DOSIO.TXT and CDCMD.TXT for examples.
  46.  
  47.     Conditional execution
  48.  
  49.     Grasp now features conditional execution in If-Else-Endif constructs,
  50.     which can be built around value comparisons, user keystrokes, mouse
  51.     clicks, and other testable conditions.  See pages 3-34 through 3-37.
  52.  
  53.     Variables, operators, and functions
  54.  
  55.     Grasp now allows variables and can perform string and math operations.
  56.     See pages 3-28 and 3-29 for an introduction to variables, and pages
  57.     6-18 through 6-20 for lists of operators and functions.
  58.  
  59.     Subroutines
  60.  
  61.     You can now pass parameters to subroutines, including variables.
  62.     See pages 3-37 through 3-41 for details.
  63.  
  64.     Typographic controls
  65.  
  66.     The Text command now wraps text within windows automatically, and you
  67.     can choose left, center, or right alignment of text.  Letter and word
  68.     spacing can also be controlled.  See page 4-88.
  69.  
  70.     Picture/clipping command use
  71.  
  72.     All Grasp commands can now work with clippings or pictures.  To use a
  73.     clipping with a command designed for pictures such as Pfade, preface
  74.     the buffer number with a C.  To use a picture with a clipping command
  75.     such as Putup, preface the buffer number with a P.
  76.  
  77. Pictor
  78.  
  79.     Quick keys
  80.  
  81.     The quick-key feature has been expanded to include more menu options
  82.     and to allow you to select all of the drawing tools.  See section six
  83.     of the Pictor manual for a complete list.  Also note that it's no
  84.     longer necessary to use the Alt key with a letter key to select menu
  85.     options or tools, unless you're using the Text tool.
  86.  
  87.     VGA color cycling
  88.  
  89.     In VGA modes you can cycle a range of colors on screen by pressing
  90.     Tab.  All colors from the left to the right mouse button color will
  91.     begin shifting positions as they do in Grasp with the Cycle command.
  92.     Tab again to speed up shifting; use Shift-Tab to slow it down and stop
  93.     it.  Press the Backspace key to reverse cycling direction.
  94.  
  95.     VGA color range adjustment
  96.  
  97.     The range of colors from the left to the right mouse button color can
  98.     be adjusted in hue, brightness, and contrast, using the Ctrl key with
  99.     the function keys.  These are listed in section six of the Pictor
  100.     manual.  Press the Asterisk key to restore the original palette, or
  101.     save the image to make the adjustments permanent.  Note that until you
  102.     save the image and reload it, any adjustments you make with this
  103.     feature affect the underlying palette.
  104.  
  105.     Edit menu and Change Colors dialog box
  106.  
  107.     When the Change Colors dialog box is displayed, you can use the Edit
  108.     menu functions Cut, Copy, Paste, and Invert Colors.  They will operate
  109.     on the selected range of colors (from left to right button color). 
  110.     Copy and Paste make it easy to move ranges of colors in 256-color
  111.     mode.  To use this feature, just click on Edit on the menu bar or
  112.     press the quick key for the function you want (C for Copy, for
  113.     example).
  114.  
  115. Artools
  116.  
  117.     Artools is now bundled with Grasp.  If you're familiar with the
  118.     previous version of Artools, you'll notice two program changes: 
  119.     TXTCLP (for converting text-mode images to graphics modes) has been
  120.     added, and TGAPIC/PICTGA are no longer included.  The Artools program
  121.     has also been eliminated:  each of the programs now has its own
  122.     interactive screen.
  123.  
  124. --------------------------------------------------------------------------
  125.  
  126.  
  127. Updating existing applications
  128.  
  129. Applications written in Grasp 3.1 will run under version 3.5 with four
  130. exceptions.  We're confident that Grasp's enhanced capabilities and
  131. performance will make converting your applications worthwhile.
  132.  
  133. 1   The TOUCH command has been eliminated.  Touchscreen users should rely
  134.     on the software provided with their screens, which can be used to
  135.     simulate keystrokes in response to touches.  Grasp programs can then
  136.     test for keystrokes instead.
  137.  
  138. 2   The FLOAT command has been enhanced with ENDFLOAT.  Float still leaves
  139.     a clipping displayed at its last location, but now it saves the
  140.     background under that clipping in a buffer.  The next Float command
  141.     restores the background from that buffer before starting its Float.
  142.  
  143.     This new feature allows you to put together a sequence of Floats to
  144.     create complex movement.  However, the Endfloat command must now be
  145.     issued after the last Float in a series.  Existing applications that
  146.     use Float may need Endfloats to work correctly.
  147.  
  148. 3   The new math operators include the dash (subtraction and negation).
  149.     Unfortunately, this means that filenames in Grasp programs cannot use
  150.     dashes unless they're enclosed in quotes.  For example, PLOAD T-12,1
  151.     will cause an error, but PLOAD "T-12",1 will work.  If you've used
  152.     dashes in filenames, add quotes or rename the files.
  153.  
  154. 4   Since text can now span multiple lines, it's imperative that all
  155.     quotes be balanced.  This was not true in version 3.1: you could leave
  156.     off the closing quote from a Text command without causing an error.
  157.     In version 3.5 the interpreter will scan lines, treating them as text,
  158.     until it finds the next quote.
  159.  
  160.  
  161. --------------------------------------------------------------------------
  162.  
  163.  
  164. Omissions from the manual (new features that didn't make it to press).
  165.  
  166. String function
  167.  
  168.     The function STRING(LENGTH,CHAR) returns a string of the specified
  169.     length filled with the specified character (or filled with the first
  170.     character of CHAR if it's longer than one character).  For example,
  171.     this command displays a line of dashes:  TEXT STRING(80,"-")
  172.  
  173. CD control
  174.  
  175.     The disk file CDCMD.TXT (in your Grasp directory) contains Grasp
  176.     routines to play audio CD's in a CD-ROM drive.  The file contains an
  177.     example of their use, which is a revision of the example on page 3-41.
  178.  
  179. DOS functions and text file manipulation
  180.  
  181.     The disk file DOSIO.TXT (in your Grasp directory) contains Grasp
  182.     routines that execute DOS commands such as Make Directory.  It also
  183.     contains routines to read and write to disk files, and a simple
  184.     example of their use.
  185.  
  186. Return variable
  187.  
  188.     The return variable @0, which is discussed on page 3-40, is also set
  189.     when a subroutine is called.  It's set equal to the subroutine's name,
  190.     which makes it easy to trace program flow when debugging or reporting
  191.     errors.  The DOS routine DOSERR, in DOSIO.TXT, uses this feature.
  192.  
  193. Exclusive OR
  194.  
  195.     The caret (^) is the exclusive-OR operator.  Comparison is bit-by-bit.
  196.  
  197. Address function
  198.  
  199.     The function ADR(variable) returns a 32-bit address in hex, containing
  200.     both the segment and offset.  For example, ADR("myname") might return
  201.     the string "0x287B3E58".
  202.     In addition, the PEEK functions and POKE commands (PEEK, PEEKL, PEEKW,
  203.     POKE, POKEL, POKEW) can use one 32-bit address parameter instead of
  204.     two 16-bit ones.  This approach, however, limits you to Poking one
  205.     value rather than multiple ones.  Here's an example:
  206.  
  207.     SET POINTER ADR("SHARY") ; put address of string "SHARY" in STRPOINTER
  208.     POKE @POINTER+4 ASC("I") ; write "I" to memory at fifth byte position
  209.     TEXT @@POINTER           ; display "SHARI"
  210.     WAITKEY
  211.  
  212. Memory and variables
  213.  
  214.     The previous example illustrates a peculiarity of memory addressing in
  215.     Grasp.  You can't use the obvious method to directly alter variables:
  216.  
  217.     SET X "SHARY"            ; put string "SHARY" into variable X
  218.     SET POINTER ADR(@X)      ; put address of X into variable POINTER
  219.     POKE @POINTER+4 ASC("I") ; write "I" to memory at fifth byte position
  220.     TEXT @X                  ; still displays "SHARY"
  221.     WAITKEY
  222.  
  223.     You have to create a variable which is the address of a string, and
  224.     refer to the string itself by double indirection.  Here's a correct
  225.     example:
  226.  
  227.     SET XPOINTER "SHARY"     ; create pointer variable to point to "SHARY"
  228.     POKE @XPOINTER+4 ASC("I"); write "I" to memory at fifth byte position
  229.     TEXT @@XPOINTER          ; display "SHARI"
  230.     WAITKEY
  231.  
  232.     This limitation is imposed by Grasp's own memory management routines,
  233.     which are designed to maximize available memory for image buffers.
  234.  
  235. Direct memory reference
  236.  
  237.     As illustrated in the manual, the indirection function @ looks at the
  238.     contents of what follows.  For example, @X refers to the contents of X
  239.     instead of the string "X".  However, if @ is used with a number
  240.     greater than 255, Grasp will interpret it as a reference to the
  241.     contents of memory at the given location, and will return the string
  242.     at that address up to the first null (ASCII 0) character.  For
  243.     example, @0x287B3E58 refers to the string at hex address 287B3E58.
  244.  
  245. New system function: Abort
  246.  
  247.     There is one additional system function called Abort that can be
  248.     turned on and off with the SET (System Control) command.  With Abort
  249.     ON (it's on by default when Grasp starts), keystrokes will cancel a
  250.     Waitkey or other timed pause.  If you set Abort OFF, all timed events
  251.     will take the allotted time--for instance, WAITKEY 100 will always
  252.     wait one second.  Set Abort off to preserve timing in applications
  253.     where it's critical.  See page 4-78 for details of the SET command.
  254.  
  255. Editing Keys
  256.  
  257.     When editing programs in the Grasp editor, the following Wordstar key
  258.     combinations can be used in addition to those listed on page 6-8 of
  259.     the manual.
  260.  
  261.     Ctrl-F     Next word               Ctrl-A     Previous word
  262.     Ctrl-R     Page up                 Ctrl-C     Page down
  263.     Ctrl-D     Next character          Ctrl-S     Previous character
  264.     Ctrl-X     Next line               Ctrl-E     Previous line
  265.     Ctrl-W     Scroll down one line    Ctrl-Z     Scroll up one line
  266.  
  267.     Ctrl-Q C   Go to end of file       Ctrl-Q R   Go to beginning of file
  268.     Ctrl-Q D   Go to end of line       Ctrl-Q S   Go to beginning of line
  269.     Ctrl-Q B   Go to start of block    Ctrl-Q K   Go to end of block
  270.  
  271.     Ctrl-K B   Mark start of block     Ctrl-K K   Mark end of block
  272.     Ctrl-K C   Copy block              Ctrl-K V   Move block
  273.     Ctrl-K R   Read in a file          Ctrl-K W   Write block to disk
  274.     Ctrl-K Y   Delete block            Ctrl-K H   Turn off block
  275.  
  276.     Ctrl-K D   Save changes & exit     Ctrl-K Q   Abandon changes & exit
  277.     Ctrl-K S   Save file & continue    Ctrl-K X   Exit to main menu
  278.  
  279.     Ctrl-N     Insert new line         Ctrl-Y     Delete line
  280.     Ctrl-G     Delete character        Ctrl-Q Y   Delete to end of line
  281.     Ctrl-P     Insert next character typed even if it's a control character.
  282.     Ctrl-V     Toggle insert on and off
  283.  
  284. When command
  285.  
  286.     A WHEN command that calls a subroutine has to use the word GOSUB
  287.     before the subroutine's name.  This is the only instance where using a
  288.     subroutine's name alone will not work.
  289.  
  290. Glib
  291.  
  292.     Ther's a new command option in Glib called Move (/M).  Like Update
  293.     (/U), it inserts the named files into the library file.  Unlike
  294.     Update, it also deletes the files from the directory.  For example,
  295.     the command
  296.  
  297.     GLIB /M MYAPP *.*
  298.  
  299.     would copy all files in the current directory into MYAPP.GL, then
  300.     delete them, leaving only MYAPP.GL.
  301.  
  302. --------------------------------------------------------------------------
  303.                           --- end of file ---
  304.