- GuiCommand: Name:TechDraw Hatch MenuLocation:TechDraw → Hatch a Face using Image File Workbenches:TechDraw SeeAlso:TechDraw Geometric Hatch, TechDraw Hatching
The Hatch tool fills a closed region in a View with a hatch pattern, which can be SVG or bitmap files. In contrary the Geometric Hatch tool uses a specific PAT pattern file, see Hatching for details.
SVG hatch pattern on a face
- Select an closed region in a View.
- Press the Hatch a Face using Image File button
- A dialog will open where you can select the pattern file, the scale and color.
- Hatching objects are vulnerable to the "topological naming problem". See TechDraw LengthDimension for more information. It is recommended that hatching be one of the last steps in your drawing process.
- Sample SVG patterns are available locally in
$INSTALL_DIR/data/Mod/TechDraw/Patterns
``` where
```python
/usr/share/freecad/data/Mod/TechDraw/Patterns
``` and also on [GitHub](https://github.com/FreeCAD/FreeCAD/tree/master/src/Mod/TechDraw/Patterns).
## Properties
- **Source**: The View and Face to receive the hatch pattern.
- **Hatch Pattern**: Full path and filename to an SVG pattern file.
- **Hatch Color**: Hatch pattern will be displayed in this color.
- **Hatch Scale**: Hatch pattern size modifier.
## Scripting
**See also:**
[TechDraw API](TechDraw_API.md) and [FreeCAD Scripting Basics](FreeCAD_Scripting_Basics.md).
The Hatch tool can be used in [macros](Macros.md) and from the [Python](Python.md) console by using the following functions:
```python
hatch = FreeCAD.ActiveDocument.addObject('TechDraw::DrawHatch','Hatch')
hatch.Source = (view1,["Face0"])
hatch.HatchPattern = hatchFileSpec
rc = page.addView(hatch)
{{TechDraw Tools navi}}
documentation index > TechDraw > TechDraw Hatch