[Main]
Name=cmd_line
Type=Function
Subtype=ROM Call
Header Files=bascmd.h
Definition=void cmd_line (CESI x1, CESI y1, CESI x2, CESI y2, CESI drawmode);
MinAMS=1.01
See Also=bascmd.h/cmd_pxlline, graph.h/DrawLine, graph.h/DrawClipLine, bascmd.h/cmd_circle, bascmd.h/cmd_linehorz, bascmd.h/cmd_linevert, bascmd.h/cmd_pton, bascmd.h/cmd_ptoff, bascmd.h/cmd_ptchg

[ROM Call]
Index=$358

[Description]
Executes TI-Basic 'Line' command.

[Explanation]
cmd_line displays the Graph Screen and draws, erases, or inverts a line
segment on it.
The parameters <I>x1</I>, <I>y1</I>, <I>x2</I>, <I>y2</I>, and
<I>drawmode</I> 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 <A HREF="$$LINK(vat.h/VarStore)">VarStore</A> function). The
parameter <I>drawmode</I> should point to one of the following values:
<BR><BR>
<TABLE BORDER CELLPADDING="3">
<TR><TD VALIGN="TOP">1</TD><TD>Draws the line.</TD></TR>
<TR><TD VALIGN="TOP">0</TD><TD>Erases the line.</TD></TR>
<TR><TD VALIGN="TOP">-1</TD><TD>Inverts pixels along the line.</TD></TR>
</TABLE>
<BR>
See also <A HREF="$$LINK(bascmd.h/cmd_pxlline)">cmd_pxlline</A>, which uses pixel
coordinates instead of window-relative ones, and
<A HREF="$$LINK(graph.h/DrawLine)">DrawLine</A> (or
<A HREF="$$LINK(graph.h/DrawClipLine)">DrawClipLine</A>) for much faster
low-level line drawing (independently of the Graph Screen).

[References]
Out=estack.h/GetValue, graphing.h/gr_active, unknown.h/ForceFloat, unknown.h/GraphActivate, unknown.h/GrClipLine, unknown.h/XCvtFtoP, unknown.h/YCvtFtoP, wingraph.h/MakeWinRect, wingraph.h/WinAttr, wingraph.h/WinLine
Out_EV_eventLoop=1
