Please enable JavaScript to view this site.

ModelMuse Help

Navigation: Online Guide to MODPATH 5

Drawing Commands File

Scroll Prev Top Next More

Miscellaneous graphics and text can be added to map-view plots through the use of a special data file called the Drawing Commands File. This file contains a series of one-line drawing commands that are executed sequentially as they are encountered in the file. A total of 18 drawing commands provide the means of plotting lines, markers, polygons, and text in a variety of styles and colors. Detailed instructions for each command are provided in Appendix C of the MODPATH documentation - Drawing Commands.

Coordinate System

All coordinates are specified in the same units as used in the flow model computations (feet or meters, in most cases). The coordinate system is defined so that the origin is located at the lower left corner of the grid in map view. The coordinate system is assumed to extend over the entire page or plot surface, including those areas outside the grid region. As an example, for a grid with 30 rows and 50 columns the origin of the coordinate system would be in the lower left corner of row 30, column 1.

Drawing Level

The order in which objects are drawn can have a significant effect on the legibility of complex drawings when plotted on devices such as monitors and printers. MODPATH-PLOT constructs the plot in the following order:

1. writes the title and draws the scale

2. draws the grid

3. draws particle data (lines and points) and stress locations (rivers, etc.)

4. draws contours

The order in which objects specified in the Drawing Commands File are drawn during the construction of the plot can be controlled by specifying one of the following drawing “levels” for each object:

level = 0; the object is not drawn

level = 1; drawn immediately after the title and scale

level = 2; drawn immediately after the grid

level = 3; drawn immediately after particle data and stress locations

level = or > 4; drawn last, after the contours

Objects within the same drawing level are drawn in the order in which they occur in the Drawing Commands File.

Clipping

Map view plots generated by MODPATH-PLOT consist of a grid rectangle that is defined by the dimensions of the grid or sub-grid that is plotted. The plot also includes border areas on all four sides of the grid rectangle. The plot title and scale appear in the bottom border area. The drawing commands provide the option of drawing objects and text anywhere on the page or to “clip” output at the edges of the grid rectangle. If the clipping indicator is on, those parts of the object that extend beyond the grid rectangle will not be drawn. In some cases, annotating a plot with text or lines that fall outside the grid rectangle can be accomplished by turning the clipping indicator off for those items.

Command Syntax

The Drawing Commands file contains a series of one line commands that are denoted by “key words” that appear as the first entry on a line. The format of a command name is a two-letter prefix that describes the type of object affected by the command:

PL = polyline

PF = polygon fill

MK = marker

TX = text

In most cases, the prefix is followed by a “.” and a suffix that describes the specific function performed by the command. Most commands contain one or more items of data that follow the command on the same line. All data in the drawing commands file is free-format. The command

PL.COLOR 6

sets the color of polylines to color number 6.

Comment lines can be added at any point in the file and are denoted by an "@" in column 1. Labeling objects with comment lines makes a file easier to understand and edit. Some commands are followed by a block of (x-y) data. The following sequence of commands draws a box with its lower left corner at (0, 0) and its upper right corner at (50,100):

@ begin a polyline

PL.BEGIN 1 1 0 1

0 0

50 0

50 100

0 100

PL.END

 

The command PL.BEGIN signals the beginning of a block of (x-y) data. In this case, the data block consists of four points that define the x-y coordinates of the four corners of the box. The command PL.END signals the end of the x-y data block. The command PL.BEGIN contains four additional data items. The first item indicates that the box will be drawn at drawing level 1. The second item indicates that the box should be clipped at the edges of the grid rectangle. The third item specifies that the box should not be filled. The final item indicates that a closed polygon should be formed by drawing the line connecting the last data point to the first data point. Note that the data items were labeled using a comment line. The command PL.END does not contain any additional data items.