Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Escape! V3.0 - <b>hppattbox()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
hpPattBox()

Draw a box filled with one of several different fill patterns


Syntax

hpPattBox(<nTop>, <nLeft>, <nBottom>, <nRight> [,<nBorder> ;
   [,<nPattern> [,<cUnits>]]])


Parameters

<nTop>
The top row of the box.

<nLeft>
The left column of the box.

<nBottom>
The bottom row of the box.

<nRight>
The right column of the box.

<nBorder>
The line type used for the border.  Defaults to 1.  Values can be:
0       No border
1       Single line
2       Double line
3       Dotted line
4       Hairline
5       0.5 point
6       1 point
7       2 point
8       3 point
9       4 point
10      6 point
11      8 point

<nPattern>
Specifies the type of fill pattern used to fill the box.
There are six different fill patterns to choose from.  To
specify a pattern use any value from 1 to 6.  If omitted,
<nPattern> will default to pattern 1. See "Appendix B -
Shades and Fill Patterns" for a description of the
available patterns.

<cUnits>
The units of measurement to used for positioning.
Defaults to 'R'.  Values for <cUnits> can be:
"R"     Rows and Columns
"I"     Inches
"M"     Millimeters


Returns

0
Successful.

-10
Font information is missing.  hpSetFont( ) must be called first.

-12
Wrong number of parameters passed.

-14
Box coordinates specified in wrong order.

-17
Incorrect parameter type was passed.


Remarks

Whenever creating custom charts or forms, try using hpPattBox() to get
that extra 'color'.

Note:  Use hpIPattBox() when using a proportional font.


Support By

All HP Laser Printers except the original HP Laserjet


Example

To create a simple vertical bar graph:

nSales86 = 23
nSales87 = 21
nSales88 = 34
hpBox(6,10,40,70)                    // outline graph
hpPattBox(40-nSales86,12,40,14,1,2)  // 86 sales bar
hpPattBox(40-nSales87,16,40,18,1,3)  // 87 sales bar
hpPattBox(40-nSales88,20,40,22,1,5)  // 88 sales bar

See Also: hpBox() hpGrayBar() hpGrayBox() hpGrayCol() hpPattBar() hpPattCol()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson