In french: iTraitH
Prints a horizontal line at specified coordinates. Unlike iNewLine
, the end of the line is squared (instead of being rounded). The line is drawn at cursor location (configured by iYPos
The print job is not started (only iEndPrinting
can be used to start the print job).
Remark: The origin (0,0) is located in the upper-left corner of the sheet. It takes the physical margins of printer into account.
// Draws a line across the page width
// Thickness: 2.5 Pica
iHLine(0, iPageWidth(), 2.5)
<Result> = iHLine(<X1> , <X2> [, <Thickness> [, <Color> [, <Style>]]])
- True if the line was printed,
- False otherwise.
Horizontal coordinate of the beginning of line (in millimeters). Value included between 0 and the page width (returned by iPageWidth).
Horizontal coordinate of the end of line (in millimeters). Value included between 0 and the page width (returned by iPageWidth).
<Thickness>: Optional real
Line thickness (in picas). By default, this thickness is equal to 1 (one Pica = 0,353 mm).
To get a thickness of 1 pixel, <Thickness> must be equal to 0. When the thickness increases, it is proportionally distributed between the two sides of line.
<Color>: Optional integer
Color used for the line. If this parameter is not specified, the color used is black.
This color can correspond to:
<Style>: Optional integer constant
Type of line.
|iDashed||Dashed line (-----)|
|iDotAndDash||Dot-and-dash line (-.-.)|
|iDotted||Dotted line (....)| Caution
: To get a dotted line, <Thickness> must be equal to 0. If <Thickness> is greater than or equal to 1, the line will always be a solid line. This parameter can be ignored if it is not supported by the printer driver.
- The line is drawn at vertical cursor location (configured by iYPos).
- The cursor position is not modified when the outline is drawn.
- The dotted type (iDotted) or the mixed type (iDotAndDash) combined with a thick border may produce unpleasant effects.
This page is also available for…