xref: /csrg-svn/lib/libplot/aed/line.c (revision 48502)
1*48502Sbostic /*-
2*48502Sbostic  * Copyright (c) 1983 The Regents of the University of California.
3*48502Sbostic  * All rights reserved.
4*48502Sbostic  *
5*48502Sbostic  * %sccs.include.proprietary.c%
6*48502Sbostic  */
7*48502Sbostic 
815520Sralph #ifndef lint
9*48502Sbostic static char sccsid[] = "@(#)line.c	5.3 (Berkeley) 04/22/91";
10*48502Sbostic #endif /* not lint */
1115520Sralph 
1215520Sralph #include "aed.h"
1315520Sralph 
1415520Sralph /*---------------------------------------------------------
1515520Sralph  *	Line draws a line between two points.
1615520Sralph  *
1715520Sralph  *	Results:	None.
1815520Sralph  *
1915520Sralph  *	Side Effects:
2015520Sralph  *	A line is drawn on the screen between (x1, y1) and (x2, y2).
2115520Sralph  *---------------------------------------------------------
2215520Sralph  */
2315520Sralph line(x1, y1, x2, y2)
2415520Sralph int x1, y1, x2, y2;
2515520Sralph {
2615520Sralph     setcolor("01");
2715520Sralph     putc('Q', stdout);
2815520Sralph     outxy20(x1, y1);
2915520Sralph     putc('A', stdout);
3015520Sralph     outxy20(x2, y2);
3115520Sralph     (void) fflush(stdout);
3215520Sralph     curx = x2;
3315520Sralph     cury = y2;
3415520Sralph }
35