Defining Attributes
The DATT command defines an attribute table entry and sets that attribute as the current default. DATT has the following definition:
For example, the following defines an attribute entry named house, which will use a 500 micron black solid line and yellow colour fill:
To use an attribute, specify the name of the attribute in the graphics command. For example, to draw a rectangle using attribute house, the command would be:
When an attribute name is not specified, the current default attribute defined by the last DATT command is assumed.
If a named attribute is used and it has not been previously defined with a DATT command, it is created with default settings. You have the option to set the line and fill colours, and the line thickness attributes by following the attribute name by an "="sign and a colour setting string. The following is equivalent to both the DATT and RECT commands of the previous example
This will create an attribute named house if it does not exist, and set the attributes as defined. Note that if house did exist, its attribute settings would have been changed, and this change will affect all previous entities that used attribute house.
Attribute Overrides
Attribute overrides also define attributes, but become part of a graphics entity and cannot be changed by changing the attribute table. Entities drawn by MAPPLOT will allow you to specify attribute overrides by defining attributes with the graphics command. For example, the following command plots a rectangle using the house attribute table entry, but specifies a line style (3) and pitch (0.5) attribute override:
Attribute overrides remain in effect for all entities that follow until the next command that specifies an attribute name. In the following example, the first rectangle uses house with no overrides, the next two use line style overrides, and the last rectangle again uses house with no overrides:
DATT house,kYt500 |
\define attribute house |
RECT 0,10,5,15,10 |
\use default attribute house |
RECT 0,20,5,25,10,,3,0.5 |
\use house with style override |
RECT 0,30,5,35,10 |
\override still applies |
RECT 0,40,5,45,10,house |
\house with no overrides |
Attribute overrides may also be applied to line colours, fill colours and thickness by following the attribute name with a colon and the override specification. The following command plots a house with a red outline, but still associates the rectangle with the house attribute:
Colour and thickness overrides will also be passed on to following commands that do not specify an attribute name, in which case they will use the currently active default attribute and overrides.
Got a question? Visit the Seequent forums or Seequent support
© 2023 Seequent, The Bentley Subsurface Company
Privacy | Terms of Use