EasyManuals Logo

Tandy 1000 Basic Reference Manual

Default Icon
411 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #281 background imageLoading...
Page #281 background image
Chapter
10
I
BASIC
Ke.ywords
PSET/PRESET/Graphics Statement
PSET
[STEP] (x,y)[,colorl
PRESET
[STEP] (x,y)[,colorl
Draws
a
point on the display.
The STEP option tells BASIC that the
(XJ)
coordinates are rela-
tive to the last point referenced.
(XJ)
specify the coordinates in which to draw the point.
X
is the
horizontal coordinate and
y
is
the vertical coordinate.
Color
specifies the color of the point.
See Chapter
8,
“Displaying Color and Graphics” for information
on coordinates and colors.
The only difference between the PSET and PRESET statements
is
the default values for
color.
If you use PSET,
color
defaults to
the foreground color. If you use PRESET,
color
defaults to the
background color.
Note:
BASIC does not print and does not issue an er-
ror message for points the coordinate values
of
which
are beyond the edge of the screen. However, values
outside the integer range (-32768 to 32767) cause an
overflow error.
Sample
Program
5
SCREEN
3
10
FOR
1=0
TO
100
20
PSET
(1,I)
30
NEXT
I’draw
a
diagonal line
to
(100,100)
40
FOR
I
=
100
TO
0
STEP
-1
50
PRESET
(1,1),0
60
NEXT
I
70 ‘clear
the
line
by
setting each pixel
to
0
80
SCREEN
0
Lines 10 to 30 draw a diagonal line on the screen from the home
position to Position 100,100. Lines 40 to 60 erase the line by
drawing another line at the same position in the background
color.
279

Table of Contents

Other manuals for Tandy 1000

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tandy 1000 and is the answer not in the manual?

Tandy 1000 Specifications

General IconGeneral
ProcessorIntel 8088
Processor Speed4.77 MHz
RAM128 KB (expandable to 640 KB)
Operating SystemMS-DOS 2.11
ManufacturerTandy Corporation
Release Year1984
StorageSingle or double 5.25" floppy disk drive (360 KB), optional hard drive
SoundTandy 3-voice sound
PortsParallel, Serial
GraphicsCGA (Color Graphics Adapter)
Graphics Modes320x200, 640x200

Related product manuals