CIRCLE

Top  Previous  Next

Syntax

 

1. circle col|{numexpr}, row|{numexpr},radius|{numexpr} [,thickness] [,shade|{numexpr}] [,color|lcolor colorname] [,scolor colorname]  [,color|lcolor rgb rrggbb] [,scolor rgb rrggbb]

 

2. circle "text|!=text|~regexp|!~regexp[@left,top,right.bottom]", col|{numexpr}, row|{numexpr},radius|{numexpr} [,thickness] [,shade|{numexpr}] [,color|lcolor colorname] [,scolor colorname]  [,color|lcolor rgb rrggbb] [,scolor rgb rrggbb]

 

Description

 

A circle with the center at the column and row specified, with the radius specified, will be drawn.  All dimensions can be specified to 2 decimal places, in the range of -255 to +255.  If used, numexpr is a Business Basic expression that generates a numeric value for the column, row, and radius.  The radius is specified as a number of columns.  For a fixed measure radius, use an expression with the inchtocols() or cmtocols() function.

 

If syntax 2 is used, then the circle is drawn relative to any occurrence of the text, or of text that matches the regular expression regexpr.  In these cases, there may be no circles drawn, or several. column and row are 0-based, in these formats, and can be negative if required. The search for text or regexpr can be limited to a region on the page by adding a suffix in the format '@left,top,right,bottom'.  To use a literal "@" character in text or regexpr, it is necessary to specify "\@".

 

If the syntax "!=text" or "!~regexpr" is used, then the search is for positions NOT equal to the text or NOT matching the regular expression.  When using the NOT syntax, only one search is performed per line in the search region.

 

Line Thickness

The optional thickness parameter may be a number from 1 to 99, indicating the number of dots or pixels to use when drawing the box outline.  The default thickness is 1 pixel.  UnForm always uses dots at 1/300 inch.  If a shade parameter is desired, then the thickness parameter is required.

 

Shading

The optional shade parameter may be used to specify a "percent gray" value of from 1 to 100.  Most laser printers can only print about 8 different shades of gray, so a value of 45, for example, may print the same pattern as 50.

 

Color

Color can be specified as "white", "cyan", "magenta", "yellow", "blue", "green", "red", or "black", or you can name an RGB value as a 6-character hex string with "rgb rrggbb", where rr is red (00-FF), gg is green (00-FF), and bb is blue (00-FF).  To distinguish colors between the line and the shade region, use "lcolor" or "lcolor rgb" for lines, and "scolor" or "scolor rgb" for shade.

 

Examples

 

The following will draw a circle centered in an 80 by 66 form, with a 2.5 inch radius, a blue 2-pixel wide border, and a 5 percent interior shade.

 

circle 40.5,33,{inchtocols(2.5)},2,5,lcolor blue

 

Drivers: all

 pcl cannot have –nohpgl specified

 zebra diameter in dots, thickness in dots, line color – black or white only, no shading