 |
cmd_line |
Function (ROM Call 0x358) |
Executes TI-Basic 'Line' command.
cmd_line displays the Graph Screen and draws, erases, or inverts a line
segment on it.
The parameters x1, y1, x2, y2, and
drawmode should point to five items on the expression stack,
which represent respectively the coordinates of the starting point, the
ending point, and the drawing mode. All coordinates are integer or floating point
values which are relative to the
current window settings (you can change them using the "Window Editor"
application, or directly by storing values in system variables "xmin" etc.,
using the VarStore function). The
parameter drawmode should point to one of the following values:
1 | Draws the line. |
0 | Erases the line. |
-1 | Inverts pixels along the line. |
See also cmd_pxlline, which uses pixel
coordinates instead of window-relative ones, and
DrawLine (or
DrawClipLine) for much faster
low-level line drawing (independently of the Graph Screen).
Uses: GetValue, gr_active, ForceFloat, GraphActivate, GrClipLine, XCvtFtoP, YCvtFtoP, MakeWinRect, WinAttr, WinLine
See also: cmd_pxlline, DrawLine, DrawClipLine, cmd_circle, cmd_linehorz, cmd_linevert, cmd_pton, cmd_ptoff, cmd_ptchg