bas7advr.hlp (
Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
PUT Statement (Graphics) Details
◄Syntax► ◄Details► ◄Example► ◄Contents► ◄Index► ◄Back►
──────────────────────────────────────────────────────────────────────────────
The PUT statement places a graphic image obtained by a GET statement
on the screen.
PUT [STEP](x!,y!),arrayname#[(indexes%)] [,actionverb]
■ STEP indicates that the given x and y coordinates are relative,
not absolute. The coordinates are treated as distances from the most-
recent cursor location, not distances from the (0,0) screen coordinate.
For example, if the most-recent cursor location were (10,10), then
PUT STEP (10,5),Ball
would put the object stored in Ball at (20,15).
■ (x!,y!) are coordinates that specify the top-left corner of the
rectangle enclosing the image to be placed in the current output
window. The entire rectangle to be put on the screen must be
within the bounds of the current viewport.
║ Note: If a WINDOW statement without a SCREEN argument appears
║ in a program before PUT, the coordinates refer to the
║ lower-left corner of the rectangle.
■ arrayname# is the name of the array that holds the image.
See the GET statement for information about the number of elements
that are required in the array, which can be multidimensional.
■ indexes% specifies that the image is retrieved starting from the
designated array element, rather than at the first array element.
■ The argument actionverb determines the interaction between the
stored image and the one already on the screen. The default
actionverb value is XOR.
actionverb Description
══════════ ═══════════════════════════════════════════════════════
XOR Inverts the points on the screen where a point exists
in the array image:
- When an image is placed on the screen against a
complex background twice, the background is
restored; this behavior is exactly like that of
the cursor.
- You can move an object around the screen without
erasing the background, thus creating animation
effects.
PSET Transfers the data point-by-point onto the screen.
Each point has the exact color attribute it had when
it was taken from the screen with GET.
PRESET The same as PSET except that a negative image (for
example, black on white) is produced.
AND Used when the image is to be transferred over an
existing image on the screen:
- The resulting image is the result of a logical
AND operation on of the stored image and the
screen.
- Points that had the same color in both the
existing image and the stored image remain the
same color.
- Points that do not have the same color in both
the existing image and the stored image do not.
OR Used to superimpose the image onto an existing image:
- The resulting image is the product of a logical OR
operation of the stored image and the screen image.
- The stored image does not erase the previous
screen contents.