How to Create a Simple Custom Hatch Pattern from Scratch
A beginner-friendly method for planning, writing, installing, and testing a simple custom PAT pattern. The article focuses on practical AutoCAD behavior rather than decorative examples, so every recommendation can be checked in a real DWG.
The workflow begins with Plan the Pattern Before Writing the PAT File, continues through Create the PAT File, and then addresses Build a Basic Parallel-Line Pattern. The final checks cover editing stability, portability, and plotted output where they are relevant.
Plan the Pattern Before Writing the PAT File
This section covers Identify the Repeating Module, Choose the Required Line Directions, and Define the Intended Drawing Units. The goal is to turn plan the pattern before writing the pat file into a sequence that can be tested and repeated in a production drawing.
Identify the Repeating Module
To identify the repeating module, work from a controlled copy of the drawing and change only the variables involved in this step. The repeat module is the smallest rectangle or parallelogram that can tile the plane without a visible break. Every line crossing one edge must continue correctly at the opposite edge. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Choose the Required Line Directions
To choose the required line directions, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Define the Intended Drawing Units
Define the Intended Drawing Units affects how reliably create custom hatch pattern can be edited, shared, and plotted. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Create the PAT File
This section covers Use a Plain-Text Editor, Add the Pattern Header, and Add the First Definition Line. The goal is to turn create the pat file into a sequence that can be tested and repeated in a production drawing.
Use a Plain-Text Editor
Use a Plain-Text Editor should be applied deliberately, with a test boundary and a known target appearance. PAT files must remain plain text. Rich-text formatting, smart punctuation, or a hidden .txt extension can make a correct definition unreadable to AutoCAD. Save as plain text, verify the real .pat extension in the operating system, and remove smart punctuation or hidden formatting.
Add the Pattern Header
To add the pattern header, work from a controlled copy of the drawing and change only the variables involved in this step. The first line begins with an asterisk, the pattern name, and an optional description after a comma. The definition lines must begin on following lines. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Add the First Definition Line
To add the first definition line, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Build a Basic Parallel-Line Pattern
This section covers Set the Line Angle, Set the Distance Between Lines, and Test the Initial Scale. The goal is to turn build a basic parallel-line pattern into a sequence that can be tested and repeated in a production drawing.
The decisions under Build a Basic Parallel-Line Pattern connect directly to building seamless brick, stone, tile, and wood patterns, which covers calculating repeat modules for material patterns without visible seams.
Set the Line Angle
To set the line angle, work from a controlled copy of the drawing and change only the variables involved in this step. The angle is measured in degrees relative to the drawing coordinate system. A second line family can use another angle to create a crosshatch. Test the angle against a known horizontal or vertical reference and confirm whether the design intent follows the world axes, the current UCS, or a material joint.
Set the Distance Between Lines
To set the distance between lines, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Test the Initial Scale
To test the initial scale, work from a controlled copy of the drawing and change only the variables involved in this step. Scale multiplies the dimensions stored in the pattern definition. Evaluate the result in model space and at the intended plotted viewport scale. Change scale by a clear factor such as 2, 10, 25.4, or 1000, then compare the pattern with a known dimension and the target paper scale.
Starter example
*CUSTOM45, Parallel lines at 45 degrees
45, 0,0, 0,5Save the definition as plain text, place it in a configured support folder, and test it in a new drawing before distributing it.
Build a Basic Crosshatch Pattern
This section covers Add a Second Line Family, Control the Crossing Angle, and Adjust the Line Spacing. The goal is to turn build a basic crosshatch pattern into a sequence that can be tested and repeated in a production drawing.
Add a Second Line Family
To add a second line family, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Control the Crossing Angle
To control the crossing angle, work from a controlled copy of the drawing and change only the variables involved in this step. Angle rotates the pattern without changing its base spacing. Check whether the required direction is relative to the world axes, the current UCS, or a material joint. Test the angle against a known horizontal or vertical reference and confirm whether the design intent follows the world axes, the current UCS, or a material joint.
Adjust the Line Spacing
Adjust the Line Spacing affects how reliably create custom hatch pattern can be edited, shared, and plotted. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Change scale by a clear factor such as 2, 10, 25.4, or 1000, then compare the pattern with a known dimension and the target paper scale.
Save and Install the New Pattern
This section covers Choose the Correct File Name, Add the File to a Support Folder, and Reload the Pattern in AutoCAD. The goal is to turn save and install the new pattern into a sequence that can be tested and repeated in a production drawing.
To verify Save and Install the New Pattern, use installing custom hatch patterns to check placing PAT resources where AutoCAD can load them on Windows and macOS.
Choose the Correct File Name
To choose the correct file name, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Use a unique ASCII-friendly name and, for a one-pattern custom file, keep the PAT filename and pattern name consistent.
Add the File to a Support Folder
To add the file to a support folder, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Reload the Pattern in AutoCAD
To reload the pattern in autocad, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Apply the setting to a small representative area, note the working value, and confirm that it supports the goal of create custom hatch pattern.
Test and Refine the Pattern
This section covers Test It on Different Boundary Sizes, Check Metric and Imperial Drawings, and Correct Scale and Alignment Problems. Additional checks complete the section. The goal is to turn test and refine the pattern into a sequence that can be tested and repeated in a production drawing.
Before standardizing Test and Refine the Pattern, review testing and debugging PAT files for finding syntax, spacing, offset, and display errors before deployment.
Test It on Different Boundary Sizes
To test it on different boundary sizes, work from a controlled copy of the drawing and change only the variables involved in this step. Boundary reliability depends on closed, coplanar geometry that is visible to the detection process. A temporary closed polyline is often the fastest diagnostic tool. Use a temporary closed polyline as a control test. If that polyline hatches correctly, repair the original contour instead of changing the PAT file.
Check Metric and Imperial Drawings
To check metric and imperial drawings, work from a controlled copy of the drawing and change only the variables involved in this step. Treat this setting as part of a controlled hatch workflow rather than an isolated option. Confirm the geometry, pattern definition, layer state, and plotted result together. Record the drawing unit, MEASUREMENT value, PAT unit assumption, and hatch scale together; none of those values should be evaluated in isolation.
Correct Scale and Alignment Problems
Correct Scale and Alignment Problems affects how reliably create custom hatch pattern can be edited, shared, and plotted. Scale multiplies the dimensions stored in the pattern definition. Evaluate the result in model space and at the intended plotted viewport scale. Pick one project reference point and assign that same origin to adjacent hatches so the repeating module continues across separate boundaries.
Verify the Pattern in a PDF Output
To verify the pattern in a pdf output, work from a controlled copy of the drawing and change only the variables involved in this step. Always separate a screen-display issue from a plot issue. Plot preview, a fresh PDF, and a second viewer provide a reliable comparison. Compare model space, plot preview, and a fresh PDF. Check the layer Plot flag, plot style, screening, lineweight, transparency, and output resolution.
Practical Verification Checklist
- Identify the Repeating Module: verify this item in a test area before applying the final hatch throughout the drawing.
- Use a Plain-Text Editor: verify this item in a test area before applying the final hatch throughout the drawing.
- Set the Line Angle: verify this item in a test area before applying the final hatch throughout the drawing.
- Add a Second Line Family: verify this item in a test area before applying the final hatch throughout the drawing.
Related CAD Hatch Guides
Use these related guides to move from the current subject into the next practical step without repeating the same troubleshooting or setup procedure.
