Creating Hatch Patterns AutoCad Help

AutoCAD provides several predefined hatch patterns you can choose from (see Figure 20.9) but you can also create your own. This section demonstrates the basic elements of pattern definition.
Unlike line types hatch patterns can not be created while you are in an AutoCAD file. The pattern definitions are contained in an external file named Acad. pat. This file can be opened and edited with a text editor that can handle ASCn files such as the Windows Notepad. Here is one hatch pattern definition from that file:

*square Small aligned squares
0 0 0 0.125 .125-.125
90 0 0 0.125 .125-.125

You can see some similarities between pattern descriptions and line-type descriptions. They both start with a line of descriptive text and then give numeric values defining the pattern. However the numbers in pattern descriptions have a different meaning. This example shows two lines of information. Each line represents a line in the pattern. The first line determines the horizontal line component of the pattern and the second line represents the vertical component. Figure 20.10 shows the hatch pattern defined in the example.

A pattern is made up of line groups. A line group is like a line type that is arrayed a specified distance to fill the area to be hatched. A line group is defined.by a line of code much as a line type is defined. In the square pattern for instance two linesone horizontal and one vertical-are used. Each of these lines is duplicated in a fashion that makes the lines appear as boxes when they are combined. Figure 20.11 illustrates this point.

Look at the first line in the definition

0 0 0 0.125 .125-.125

This example shows a series of numbers separated by Commas it represents one line group. It actually contains four sets of information separated by blank spaces:
• The first component is the 0 at the beginning. This value indicates the angle of the line group as determined by the line’s orientation. In this case it is 0 for a horitontalline that runs from left to right.
•The next component is the origin of the line group 0 O. This does not mean that the line actually begins at the drawing origin (see Figure 20.12). It gives you a reference point to determine the location of other line groups involved in generating the pattern.

NOTE

If you have forgotten the numeric values for the various directions refer back to Figure 2.4 in Chapter 2 which shows AutoCAO’s system for specifying angles.

The next component is 0 .12 (This determines the distance for arraying the line and in what direction as illustrated in Figure 20.13. This value is like a relative coordinate indicating x and y distances for a rectangular array. It is not based on the drawing coordinates but on a coordinate system relative to the orientation of the line. For a line oriented at a 0° angle, the code 0, .125 indicates a precisely vertical direction. For a line oriented at a 45° angle the code 0, .125 represents a 135° direction. In this example the duplication occurs 90° in relation to the line group because the x value is O.Figure 20.14. illustrates this point

FIGURE 20.13:

FIGURE 20.13:

The last component is the actual description of the line pattern. This value is  equivalent to the value given when you create a line type. Positive values are line segments and negative values are blank segments. This part of the

line-group definition works exactly as in the line-type definitions you studied in the previous section.

This system of defining hatch patterns may seem somewhat limiting but you can actually do a lot with it. Autodesk managed to come up with 53 patterns and that was really only scratching the surface.

TIP

If you want to include thick lines in your hatch patterns you have to “build up” line widths with multiple line-type definitions. You may also use the Super Hatch Express tool discussed in Chapter 19.

If You Want to Experiment 

In the first part of this chapter you learned that you can create your own toolbars then you went on to learn how to create yow’ own menu. Try adding custom toolbars to the menu you created in the Adding Your Own Pull-Down Menu section.
1. If you haven’t done so already, load the Mymenu mnu file into the AutoCAD menu bar.
2. Right-click a button in any toolbar, then select Customize in the popup menu  The Toolbars dialog box opens.
3. Select Mymenu from the Menu Group d{op-down list.

Since you don’t have toolbars coded into your menu file, the Toolbars list box is empty. The next step is to add a toolbar to your custom menu.

1. Click the New button. The New Toolbar dialog box appears.
2. Enter My Toolbar in the Toolbar Name input box and then click OK. A small, blank toolbar appears in the AutoCAD window.
3. Click Customize in the Toolbars dialog box. The Customize Toolbars dialog box appears.
4. Open the Categories pull-down list. Notice that the list contains the main categories of commands.
5. Choose Draw from the list. The list box displays all the tools available for the Draw category. Notice that the dialog box offers several additional arc and circle tools not found in the Draw toolbar
6. Click the-first tool in the top row: the Line tool. You’ll-see a description of the tool in the Description box at the bottom of the dialog box.
7.’ Click and drag the Line tool from the Customize Toolbars dialog box into the new toolbar you just created. The Line tool now appears in your toolbar.
8. Click and drag the Arc Start End Direction tool to your new toolbar.
9. Exit the Customize Toolbars dialog box and the Toolbars dialog box.

Posted on November 9, 2015 in Integrating AutoCAD into Your Projects and Organization

Share the Story

Back to Top
Share This