I hope you might have enjoyed the Part II of AutoCAD 2010 Customization, I’ve tested these tutorials for AutoCAD 2010 and works fine.
Well, After line type next in the series is AutoCAD HATCH PATTER
By default, HATCH defines the boundary by analyzing all closed objects in the drawing
Let’s create a simple square and hatch it with the linetype ATP171 as shown below

Now hatch the above square of sides 10mm

Note:
Have you noticed that the Hatch line is also ATP171 linetype.
In today’s class we shall see how to customize AutoCAD Hatch Patters
Before this we should know where the hatch patters are stored in AutoCAD 2007 and with what
extension
Generally AutoCAD has their hatch pattern stored in
C:\Documents and Settings\Administrator\Application Data\Autodesk\AutoCAD
20XX\R17.0\enu\Support\acad.pat
The extension for the pattern file is *.pat
Make sure, the acad.pat file is safe and a backup is created before you try to play with the file
*************
portion of ACAD.pat file (end)
*ZIGZAG, Staircase effect
0, 0,0, .125,.125, .125,-.125
90, .125,0, .125,.125, .125,-.125
;;
;; User Defined Hatch Patterns
;; Add any hatch patterns that you define to this section of
;; the file to ensure that they migrate properly when
;; upgrading to a future AutoCAD version. If duplicate hatch
;; patterns are found in this file, items in the User Defined
;; Hatch Patterns section take precedence over patterns that
;; appear earlier in the file.
;;
************************************************************************
NOTE:
Again you might have noticed that in the Hatch Patter file few details were intentionally
made bold with RED color. This is to help you understand that any new hatch pattern type
created in AutoCAD can be saved in acad.pat file rather than saving them in a new file. Thereby
ensuring easy migration of the new hatch types to the next release of AutoCAD.
Now before we start creating the hatch patterns let’s review some basic information
Hatch patterns are defined in one or more Hatch pattern definition files that have a .pat file
extension
When you create a pattern file, you must load the file before you can use it.
The pattern files included in AutoCAD are acad.pat and acadiso.pat
You can display or print these text files to better understand how to construct patterns
PAT files must always be saved in ASCII format and use an .pat file extension
Hatch Pattern Definition [THEORY]
Each hatch pattern definition occupies two lines in the acad.pat file. The first line generally helps
us in knowing the name of the hatch pattern and a short description. While the second line gives details
about the coding and format. We shall take a simple hatch pattern from acad.pat and see how it goes.
*ANSI31, ANSI Iron, Brick, Stone masonry
45, 0,0, 0,.125
Based on the above line we can develop a simple generalized structure
as shown below
* Pattern_Name, Pattern Description
Codes to define the Pattern
Further w.r.t to codes the detailed format is given below. Every Hatch Pattern should include all or some
of them to define a final pattern
Codes – Angle, X – Origin, Y – Origin, Delta x, Delta y, Dash -1, Dash -2
Therefore general structure is given below
* Pattern_Name, Pattern Description
Angle, X – Origin, Y – Origin, Delta x, Delta y, Dash -1, Dash -2
——————————————————————————————–
*ANSI31, ANSI Iron, Brick, Stone masonry
45, 0,0, 0,.125
The pattern name on the first line, *ANSI31, is followed by a description: ANSI Iron, Brick, Stone
masonry. This simple pattern definition specifies a line drawn at an angle of 45 degrees, that the first
line of the family of hatch lines is to pass through the drawing origin (0,0), and that the spacing between
hatch lines of the family is to be 0.125 drawing units.
Hatch pattern definitions follow these rules:
• Each line in a pattern definition can contain up to 80 characters. You can include letters,
numbers, and the special characters
• You must begin a pattern definition with a letter or number, not a special character.
• AutoCAD ignores both blank lines and text to the right of a semicolon.
• Each pattern line is considered to be the first member of a line family, created by applying the
delta offsets in both directions to generate an infinite family of parallel lines.
• The delta-x value indicates the displacement between members of the family in the direction of
the line. It is used only for dashed lines.
• The delta-y value indicates the spacing between members of the family; that is, it is measured
perpendicular to the lines.
• A line is considered to be of infinite length. A dash pattern is superimposed on the line.
Let’s take a simple example and see how it works
* Pattern_Name, Pattern Description
Angle, X – Origin, Y – Origin, Delta x, Delta y, Dash -1, Dash -2
Problem 01
* Dash Dot90, Dash and Dot lines at 90 Degree
90, 0, 0, 0.15, 0.15, 0.255, -0.255, 0, -0.255
Explanation
• * – This represents the Asterisk
• Dash Dot90 – This represents the Name of Hatch Pattern
• Dash and Dot lines at 90 Degree – This represents the Hatch Description
• 90, 0, 0, 0.15, 0.15, 0.255, -0.255, 0, -0.255
• 90 – This represents the Angle of Hatch Line
• 0 – X – Origin
• 0 – Y – Origin
• 0.15 – Delta X
• 0.15 – Delta Y
• 0.255, -0.255, 0, -0.255 – This represents the line type definition
Let’s see in the next class how to create them using NotePad and directly embed in AutoCAD.,
I hope you enjoyed the third part of AutoCAD Customization.
**********
Well, pls do comment your experience level after learning these tutorials, your comments (positive / critic) will serve the CAD Community in a better way.