Fundamentals > Creo Parametric User Interface > The View Tab > Cross Sections > Working with Cross Sections > Linear and Non-linear Cross-Hatch Patterns
  
Linear and Non-linear Cross-Hatch Patterns
The patterns are created using the Creo Hatch editor and are saved in a special Creo format. Each hatch pattern is stored as a separate file. The following are the benefits:
Support both linear and non-linear hatching patterns.
Use a simple pattern hatching format that can be edited using basic tools such as a Notepad editor or download a free editor tool from the Internet.
File Structure
The *.pat file includes linear and non-linear hatch patterns. Each hatch pattern begins with an asterisk character (‘*’) which indicates a new pattern. The basic structure of a hatch pattern is as follows: *pattern-name, standard-name, description
The asterisk character is followed by a series of strings separated by commas (‘,’). The first string provides the pattern’s name.
The second string provides the name of the pattern’s standard.
The third string provides the description of the pattern.
Any other string added and separated by a comma is considered part of the description.
 
If only a description exists it is referred to as both the group’s name and description, for example, *ANSI32, Steel
If the group’s name is empty, it is considered as a part of the miscellaneous group patterns, for example, *ANSI32, Steel
If the group’s name and description are missing the pattern is added to the miscellaneous group patterns
For example, *ANSI131, ANSI, ANSI Iron, Brick, Stone masonry
In the above example:
ANSI131 is the pattern name
ANSI is the standard name
ANSI Iron, Brick, Stone masonry is the description
The following line consists of a series of numeric values separated by commas. These values define the hatching lines of the pattern as follows: angle, x-origin, y-origin, delta-x, delta-y, dash-1, dash-2, dash-3, dash-4…
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 line.
The angle is defined as the measured angle between the x-axis and the line (in a counter clockwise measuring method).
The x-origin and y-origin are the drawing origin of the family of hatch 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 and is measured perpendicular to the lines.
A line is considered to be of infinite length. A dash pattern is superimposed on the line.
The x and y line spacing values are followed by a series of values that represent the line type definition:
A positive value specifies a dash
A negative value defines a space
A zero value specified a dot
Any non-empty line starting with a semicolon (‘;’) is considered as a comment
Creo Hatching Pattern Files
The system also supports numerous *.pat files.
Creo provides, out of the box, a default xhatch.pat file that contains a number of pre-defined patterns. The default *.pat is placed by default in the following directory path which is the current default directory of the hatch pattern file that is currently used: ..\Common Files\U070\text\crosshatch
The user may add more pat files to the following:
The default directory or to other directories within the parent directory
The working directory
The directory specified by the configuration option
It is recommended to place the *.pat file in the default directory or to use the configuration option and place the hatching pattern file in the directory specified by the configuration option.
Configuration Option
The configuration option pro_crosshatch_dir currently used for specifying the location directory of *.xch files is also used for specifying a directory where the pat files is placed.
File Location
The system searches for *.pat files in the same order that it currently searches for *.xch files in the following places:
The user’s work space (for a linked session)
The working directory
The default directory ..\Common Files\U070\text\crosshatch
The directory set by the configuration option pro_crosshatch_dir
Any hatching patterns found in the files are made available when the system loads
Handling Same Name Files
The system handles pat files with the same name when placed in different directories. The hatch pattern data in the files is handled and added as any other data to the general hatch pattern data pool.
Handling Data Duplication
When the hatch pattern data is exactly the same as another pattern data in the same *.pat or other *.pat files, the system compares the pattern data and decides how to add the hatch pattern data to the general pool of data.
When the pattern data that is exactly the same in all aspects such as name, standard name, description, and pattern values as another pattern data, it is skipped and not added.
If hatching patterns with the same name and standard name but a different set of line pattern definitions are encountered, all these patterns are added to the hatch pattern data pool. These patterns are distinguished by an added postfix in the form of an underscore and index number (‘_#’ ) which is added to the name of the hatch patterns. The example is as follows:
*ANSI32, ANSI, Steel
45, 0, 0, 0, 9.525
45, 4.49013, 0, 0, 9.525
And
*ANSI32, ANSI, Steel
60, 0, 0, 0,9.525
60, 0, 0, 0, 9.525
In the above example the first ANSI hatching pattern name is ANSI32 and the second ANSI32_1.
If all the hatching data is exactly the same apart from the description, the first such hatching pattern is added and the rest is discarded.
Retrieving Hatch Patterns
You can retrieve hatch patterns from the Edit Hatching dialog box. You can filter the hatch patterns by selecting the appropriate option from the Hatch Patterns list box.
 
* When you select Legacy from the list box, only legacy hatch patterns are displayed.
.
Updating and Saving the Hatch Pattern Scale
The following commands are available for updating the scaling factors from a *.cfg file or to save the hatch scaling factors to a *.cfg file.
Open scale settings — Reads the scale setting from a *.cfg file. When you click this command, the Open dialog box appears, which displays the most recently used files. If the scale file that was opened does not contain all of the displayed hatch patterns then their scaling factor remains as displayed in the hatching gallery.
Save scale settings — Writes all the scale hatch pattern settings in the gallery to a *.cfg file. When you click this command, the Open dialog box appears, which enables browsing and selecting a location to save the *.cfg file.
To open the Open scale settings and Save scale settings commands, right-click the hatch pattern on the Edit Hatching dialog box.