drawLine

drawLine( x1, y1, x2, y2 )

Draws a 1 pixel wide line from x1 by y1, to x2 by y2.

// an example of drawing a diagonal line
// from 10x10 to 100x100
drawLine( 10, 10, 100, 100 )

drawLine( x1, y1, x2, y2, width )

Width this you can specify a line 'width', in pixels, which is used when the line is drawn.

// draws a very wide, diagonal line
drawLine( 10, 10, 100, 100, 50 )