rcrpanel man page

rcrpanel — Create a PostScript file of a panel from a script

Synopsis

rcrpanel filename

Description

rcrpanel reads a script file describing a panel and produces a PostScript image of that panel on the standard output.

Options

none

Input File

The input file contains lines describing the various controls. Most lines are of the form Command = something where the spaces around the equal sign are significant, and the command itself is case-sensitive.

Measurements are in units of millimeters. Angles are in degrees. Colors are given as 24 bit C style integers where each byte repesents the amount of red, green, or blue.

Commands

Reverse -
This command takes no arguments. If this command appears anywhere in the input file, the resulting PostScript will be flipped left to right (for printing on the reverse side of transparency material).
ControlLarge -
This is used for large diameter controls such as large pots and the like. It takes 2 values after the equal sign representing the position of the control on the panel.
ControlPhone -
This is used for 1/4" phone jacks and similar controls. The 2 values after the equal sign represent the position on the panel.
ControlLED -
This command generates an outline for a 5 mm LED. Like the other control commands, it takes 2 values, the X and Y positions on the panel of the center of the LED.
ControlSmall -
This command generates an outline for a 3.5 mm phone jack. The two values are the X and Y positions of the jack on the panel.
ControlTiny -
This command generates an outline for a 2.5 mm phone jack. The two values are the X and Y positions of the jack on the panel.
Panel -
This command defines the size of the panel. The 2 dimensions are the width and height of the panel.
Background -
This command takes a single color following the equal sign. The entire panel will be filled with this color.
Text -

This command is somewhat different from the others. After the equal sign, it takes 3 floating point numbers, a color, and a text string. The fist 2 floating point numbers are the X, Y position of the text on the panel. The third number is the height of the text. The color represents the color of the text, and the text string represents the font to be used. No checking is done before preparing the PostScript; you are responsible for ensuring that the font is available on your printer.

This command is then followed by another line containing the text to be displayed.

Dial -
This command introduces a new dial. The Dial command describes the X,Y center of the dial. The following commands then further refine the details of this particular dial. This relationship between the Dial command and it's successors is the only place where the order of the commands within the file matters.
Radius -
This command takes a single value which is the radius of the circle which forms the inside of the tick marks. This command refers to the current Dial command.
Span -
This command describes the angle over which the control may operate. Typically, this would be 270 for a potentiometer and 180 for a variable capacitor. This command refers to the current Dial command.
NumTicks -
This command describes the total number of tick marks, large and small, to be drawn. This is usually an odd number since the starting and ending values are counted. Typically this will be 11, 101, or a similar number. This command refers to the current Dial command.
BigPer -
This command tells the program how many small tick marks there are per large tick mark. This command refers to the current Dial command.
SizeTicks -
This command describes the length of the small tick marks. This command refers to the current Dial command.
SizeBig -
This command describes the length of the large tick marks. This command refers to the current Dial command.
StartingIndicator -
This command describes the value to be placed on the furthest counterclockwise large tick mark. This command refers to the current Dial command.
IncrementPerBigTick -
This command tells rcrpanel how much to increment the value in StartingIndicator for each succeding large tick mark. This command refers to the current Dial command.
SizeFont -
This command describes how large to make the annotation on the ticks. This command refers to the current Dial command.
ColorCircle -
This command takes a single color as an argument, which is used to draw the inner circle. This command refers to the current Dial command.
ColorTickMarks -
This command permits setting the color to draw the small tick marks. This command refers to the current Dial command.
ColorBigTickMarks -
This command permits setting the color to draw the large tick marks. This command refers to the current Dial command.
ColorText -
This command accepts a single color which will be used for the annotation. This command refers to the current Dial command.
StartAngle -
By default, rcrpanel arranges dials so the dead spot on the control is straight down. This is the desired behavior in almost all cases. However, sometimes you may want to rotate a control to some other orientation. The single argument to StartAngle is the number of degrees clockwise to rotate the control. This command refers to the current Dial command.

Limitations

Current compiled in limits are 20 dials, 50 controls and 50 text strings. Strings are limited to 127 characters and font names may be no more than 31 characters long.

Author

John J. McDonough, WB8RCR

Bugs

None known

rcrpanel is still lacking the ability to draw random straight lines on the panel.

Info

13 Mar 2009