Skip to content

Latest commit

 

History

History
133 lines (74 loc) · 4.16 KB

EM_FHNode.md

File metadata and controls

133 lines (74 loc) · 4.16 KB
Error in user YAML: (<unknown>): did not find expected alphabetic or numeric character while scanning an alias at line 5 column 14
---
- GuiCommand:
   Name: EM FHNode
   MenuLocation: EM -> FHNode
   Workbenches: EM_Workbench
   Shortcut: **E** **N**
   Version: 0.17
   SeeAlso: EM_FHSegment, EM_FHPath, EM_FHPlane, EM_FHPlaneAddRemoveNodeHole, EM_FHEquiv, EM_FHPort
---

EM FHNode

Description

The FHNode tool inserts a FastHenry node object.


FastHenry FHNode

Usage

The FHNode object can be based on the position of a Draft Point object, or you can select the 3D location of the FHNode.

  1. Press the EM FHNode button, or press E then N keys.
  2. Click a point on the 3D view, or type coordinates and press the add point button.

Alternatively, you can also:

  1. Select one or multiple Draft Point object(s)
  2. Press the EM FHNode button, or press E then N keys. As many FHNodes will be created as the Draft Point objects, at the same coordinates of the Draft Points.

Options

  • To enter coordinates manually, simply enter the numbers, then press Enter between each X, Y and Z component. You can press the add point button when you have the desired values to insert the point.
  • Click the checkbox to toggle continue mode. If continue mode is on, the FHNode tool will restart after you place a node, allowing you to place another one without pressing the tool button again.
  • Press Esc or the Close button to abort the current command.

Properties

  • X: the X coordinate of the node

  • Y: the Y coordinate of the node

  • Z: the Z coordinate of the node

Scripting

See also:

FreeCAD Scripting Basics.

The FHNode object can be used in macros and from the Python console by using the following function:

node = makeFHNode(baseobj=None, X=0.0, Y=0.0, Z=0.0, color=None, size=None, name='FHNode')
  • Creates a FHNode object.

  • baseobjis the Draft Point object whose position can be used as base for the FHNode. It has priority over X, Y, Z. If no baseobj is given, X,Y,Z are used as coordinates.

  • Xx coordinate of the node, in absolute coordinate system.

  • Yy coordinate of the node, in absolute coordinate system.

  • Zz coordinate of the node, in absolute coordinate system.

  • coloris the node color, e.g. a tuple (1.0,0.0,0.0). Defaults to EMFHNODE_DEF_NODECOLOR.

  • sizeis the node size. Defaults to EMFHNODE_DEF_NODESIZE.

  • nameis the name of the object

The placement of the FHNode can be changed by modifying its Placement property, or changing the X,Y,Z properties individually. Changing X,Y,Z modifies the node position in the relative coordinate system of the Placement.

Additionally, the _FHNode class exposes these methods. The _FHNode class can be accessed through the FHNode object Proxy (e.g. fhnode.Proxy).

pos = getAbsCoord()
  • Get a FreeCAD.Vector containing the node coordinates in the absolute reference system
pos = getRelCoord()
  • Get a FreeCAD.Vector containing the node coordinates relative to the FHNode Placement
pos = setRelCoord(rel_coord, placement=None)
  • Sets the node position relative to the placement

  • rel_coordis a FreeCAD.Vector containing the node coordinates relative to the FHNode Placement

  • placementis a new FHNode placement. If None, the placement is not changed

pos = setAbsCoord(abs_coord, placement=None)
  • Sets the absolute node position, considering the object placement, and in case forcing a new placement

  • abs_coordis a FreeCAD.Vector containing the node coordinates in the absolute reference system

  • placementis a new FHNode placement. If None, the placement is not changed

Example:

import FreeCAD, EM

fhnode = EM.makeFHNode(X=1.0,Y=2.0,Z=0.0)

{{EM Tools navi}}


documentation index > EM > EM FHNode