Original Author Paul Laughton, 2011
Page 162
De Re BASIC!
Gr.close
Closes the opened graphics mode. The program will continue to run. The graphics screen will be
removed. The text output screen will be displayed.
Gr.front flag
Determines whether the graphics screen or the Output Console will be the front-most screen. If flag = 0,
the Output Console will be the front-most screen and seen by the user. If flag <> 0, the graphics screen
will be the front-most screen and seen by the user.
One use for this command is to display the Output Console to the user while in graphics mode. Use
Gr.front 0 to show text output and Gr.front 1 to switch back to the graphics screen.
Note: When the Output Console is in front of the graphics screen, you can still draw (but not render)
onto the graphics screen. The Gr.front 1 must be executed before any Gr.render.
Print commands will continue to print to the Output Console even while the graphic screen is in front.
Gr.brightness <nexp>
Sets the brightness of the graphics screen. The value of the numeric expression should be between 0.01
(darkest) and 1.00 (brightest).
Graphical Object Creation Commands
These commands create graphical objects and add them to the Object List, also adding their Object
Numbers to the Display List. You create each object with parameters that describe what to draw and
where. Once it is created, you can read back its parameters by name with the Gr.get.value command.
You can change any parameter with the Gr.modify command. The parameters you can modify are listed
with each command's description. Along with the parameters listed with each command, every
graphical object has two other modifiable parameters, "paint" and "alpha". See the Gr.modify and
Gr.paint.get command descriptions for more details.
There are three commands that create graphical objects that are not in this section: Gr.text.draw,
Gr.bitmap.draw, and Gr.clip.
Gr.point <obj_nvar>, x, y
Creates a point object. The point will be located at (x,y). The <obj_nvar> returns the Object List object
number for this point. This object will not be visible until the Gr.render command is called.
The appearance of the point object is affected by the current stroke weight and the AntiAlias setting.
The object is rendered as a square, centered on (x,y) and as big as the current stroke. If AntiAlias is on, it
will blur the point, making it larger and dimmer. To color a single pixel, use Gr.set.stroke 0 and
Gr.set.antialias 0.
The Gr.modify parameters for Gr.point are: "x" and "y".