Resource: color_fill
Resource | color_fill |
Command Line | -cof=[value:]color[:attribute...],[value:]color[:attribute...],... -cof=filename |
Environment Variable | wxpclrfill |
Default Value | magenta, lmagenta, blue, lblue, cyan, lcyan, green, lgreen, brown, yellow, red, lred, dgray, lgray, white |
This resource is used to specify a list of colors and attributes for color fill contours. Up to a total of 256 colors may be specified separated by commas. Also, a value of "end" automatically terminates the list. A value of "off" tells the contouring algorithm not to display that contour level. Each color/attribute may be preceded by a value which specifies the exact contour value to use for that color. The value represents the low end of the fill area. Color fill attributes also apply to line contours which allows line contours to have different style. The line contour colors can also color fill colors is the value of the color_cont resource is "off".
Contouring
The color_fill resource allows a great deal of tailoring of contour plots and satellite images. The syntax for each color fill parameter is:
[value:]color[:attribute...]
In the simplest form, the color fill list is just a list of colors to be used by the program to display color fill contours. The first color is associated with the lowest contour value unless changed with the con_base resource.
magenta,lmagenta,blue,lblue,cyan,lcyan,green,lgreen,brown,yellow,red,lred,dgray,lgray,white
Each color may also have attributes listed which modify the appearance of the color fill contours.
dgray:fi=vln,dgray
which uses a different fill pattern for the first color fill range. This can be used in conjuntion with line contours if the color_cont resource is set to "off". These attributes can be used to tailor the lines:
brown,brown:st=dot,brown:st=dot,brown:st=dot,brown:st=dot
which is used to make every 5th line solid and all others dotted.
Color ranges may also be specified to simplify the list. For example:
2-4 or red-blue
would be equivalent to red,green,blue. The attributes for the entire range come from the attributes listed for the first color in the range.
Finally, values can be attached to each color fill value. This locks in a particular color to a specific contour range and can specify contour values which are not regular and thus cannot be specified with the con_interval resource.
.01:DDMagenta,.05:DMagenta,.1:MMagenta,.175:BMagenta,.25:Blue, .375:LBlue,.5:Green,.75:LGreen,1:Brown,1.5:Yellow,2:Red, 3:Lred,4:LGray
This specifies the color fills for a precipitation field. When values are specified, a color bar automatically appears since this is necessary to denote irregular contour values.
As color fill settings get more complicated, it becomes more convenient to put the values in a file. WXP has a color fill file that can be specified with the color_fill resource:
-cof=prec.cfl
The file has the same information except the values are put of different lines without the commas:
.01:DDMagenta .05:DMagenta .1:MMagenta .175:BMagenta .25:Blue .375:LBlue .5:Green .75:LGreen 1:Brown 1.5:Yellow 2:Red 3:Lred 4:LGray
Up to 256 color fill values can be specified.
Contour LabelsThe labels on the contour plot and color bar are based on the value listed. For example, the first value listed would be labeled ".01". To change this label, use the label parameter ".01:DDMagenta:la=min" or "85:red:la=HOT".
Line Contours
The color_fill resource is used to specify the attributes for each line contour. If this resource is specified, the lowest contour gets the first attribute listed and the next lowest, the second attribute listed and so on. This allows each line contour to be a different color.
If the color_cont resource is set to "off", the colors from the color_fill resource carry over to the line contours as well allowing each line to be a different color.
Radar Plots
For radar plots, the color_fill resource acts much like a plot of a color fill contour. The default for a MDR plot is "off, blue, cyan, green, yellow, red, magenta". The default for most other plots is the same as the default scale for other color fill plots.
Satellite Enhancement
Satellite enhancement uses the existing color fill setup where values can be specified for colors. The major differences are as follows:
- The color values are image pixel values ranging from 0 to 255.
- The value may be specified as a image pixel value or as a infrared temperature based on
the GOES conversion scheme. The temperature is specified by preceding the value by a
"c". For example, "c-25" specifies the image pixel value
corresponding to -25 Celsius. This way infrared images can be enhanced based on the
temperatures the image represents.
NOTE: This works only for increasing image pixel values. As the image pixel values increase, the temperatures DECREASE and therefore temperature values must be listed in decreasing order. - The colors can be specified with dither value and color. This is handy for screens that
cannot support gray shades such as monochrome displays. Dither colors are specified by
using the following syntax:
black%6white
The original or background color is specified followed by a "%", then the dither percent value and the dither or foreground color. The above example uses the 3x3 dither matrix and gives possible dither values of 0 through 9. The result is a 6/9 dither of white over black. Using 0 for the dither value gives the original color. Using 9 for the value gives the only dither color. This is somewhat restrictive for monochrome screens, so a second dither scheme is provided which is a 5x5 dither matrix. This gives a total of 26 possible dither values which are specified by lower case alphabetic characters "a" through "z". The value "a" gives the original color and "z" gives the dither color. For example:
black%mwhite
gives a 12/25 dither.
The color fill file or more appropriately the enhancement file has an additional line at the beginning of the file that names the enhancement. Here is the MB enhancement file:
MB 0:black c29:1 2-9 c6:10 11-15 c-31:16 c-32:cyan c-43:lcyan c-54:lblue c-60:blue c-64:green c-70:lgreen c-76:brown c-81:yellow c-90:black
Additional Attributes
Attribute | Description |
co=color | Specifies the color. This is the color name from the color table. If this is the first attribute, the "co=" may be omitted. |
wi=width | Specifies the width of lines. This includes lines used in text and markers. The default value is 1.0. |
st=style | Specifies the style of lines. Possible values are:
|
fo=font | Specifies the font number. See the font_list resource. |
fi=fill fp=fill |
Specifies the fill pattern. Possible values are:
|
sc=scale hi=height |
Specifies the scale factor. For text, this is the text height. For markers, this is the size of the marker. The default value is 1.0. |
te=expan | Specifies the text expansion factor. This controls how wide text is plotted. An expansion factor greater than 1 results in fat text. A value less than 1 results in thin text. The default value is 1.0. |
la=label | Specifies the contour label. This appears on the contour labels on the plot and on the color bar. The label defaults to the contour value or the value listed in the color_fill resource. ".01:DDMagenta" would plot ".01" and "85:red:la=HOT" would plot "HOT". |
Each of these can be specified with single characters (backward compatible with version 4). For example "w1.0" can be used for width, "h1.0" can be used for height, "s3" can be used for style, "f8" can be used for fill pattern, "t2" can be used for font, and "e1.0" can used for text expansion.
Last updated July 30, 1998