legend [ parameter=value ...] [ inputfile outputfile ] legend [ parameter=value ...] [ inputfile ... directory ]
Parameters are: line_n, text_height, text_type, line_offset, sample_offset, full_width, center_text, outline, solid_bg, compute_latlon, display .
This function is used to create a multi-line text legend metafile relative to a given input dataset. The size of the image over which a given legend will be drawn is determined from the corresponding input dataset.
A legend can consist of up to 8 text lines, and optionally can have a solid color background and/or an outlining rectangle. Text and outline are defined with one color, the solid background with a second color.
The size of the background and outline rectangle are automatically computed, based on the text height and type, which are user-specified. Optionally, legends can be defined so they are as wide as the image. Lines of text can be centered relative to the background, or can be left justified. Legend placement is controlled by user-specified offsets from the edges of the image.
A legend may include attributes of the corresponding input dataset. The string %attribute-name is replaced by attribute-value. For example, %satellite might be replaced by noaa-11. Dates, times, latitudes, and longitudes are expanded using standard output formats (See formats). If there is no value for a particular attribute, no substitution occurs. If a % character is required in a legend, it must be preceded by the escape character \.
A special parameter is provided for fixing the center_lat and center_lon attributes so they reflect the true center of the input image. Ordinarily, these attributes help define the map projection and do not necessarily coincide with the center of the data. Subsetting an image registered to a map projection can cause such a discrepancy.
legend can be run only when the X server is running. The X server is needed to get text width and line spacing information.
% legend in/out files : char(255) ? n11.93195.1103 n11.93195.1103.legend line_1 : char(255) ? This is an example of adding a Legend line_2 : char(255) ? [] to a dataset. line_3 : char(255) ? [] text_height : int ? [18] 12 text_type : char( 6) ? [plain] italic line_offset : int ? [0] -10 sample_offset : int ? [0] -15 full_width : char( 3) ? [no] center_text : char( 3) ? [no] yes outline : char( 3) ? [no] yes solid_bg : char( 3) ? [yes] %
Last Update: $Date: 1998/10/12 19:59:29 $