void drawLine(int X1, int Y1, int X2, int Y2, int LineWidth)

Draws a Line between two points defined by the coordinates X1/Y1 and X2/Y2. The line will be drawn with the size defined in the fifth parameter LineWidth. A given value for that parameter will also overwrite the explicit property LineWidth.

Example:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// create new PDF_Writer object
PDF_Writer.Writer PDF = new PDF_Writer.Writer();
 
// set LineWidth to 4 points
PDF.LineWidth = 4;
 
// draw line between two points
// Start-Point: X=50 Y=150
// End-Point: X=200 Y=100
// Line-Width: 2 
PDF.drawLine(50, 150, 200, 100, 2);
 
// draw another line to demonstrate how PDF.LineWidth is overwritten
// so the following line will also be drawn with LineWidth=2
PDF.drawLine(50, 150, 50, 300);
 
// save PDF document to file system
PDF.save(@"C:\PDF_Writer\test.pdf");