GuiCommand: Name: Sketcher ConstrainPointOnObject MenuLocation: Sketch , Sketcher constraints , Constrain point on object Workbenches: Sketcher_Workbench Shortcut: O SeeAlso: Sketcher_ConstrainCoincidentUnified, Sketcher_ConstrainCoincident
Sketcher ConstrainPointOnObject
Description
The Sketcher ConstrainPointOnObject tool fixes points on edges or axes. Lines are treated as infinite, and open curves are virtually extended as well.
(v1.0)
: This tool is replaced by the Sketcher ConstrainCoincidentUnified tool if the Unify Coincident and PointOnObject option is selected in the preferences.
Usage
See also: Drawing aids.
Continue mode
- Make sure there is no selection.
- There are several ways to invoke the tool:
- Press the
Constrain point on object button.
- Select the Sketch → Sketcher constraints →
Constrain point on object option from the menu.
- Use the keyboard shortcut: O.
- Press the
- The cursor changes to a cross with the tool icon.
- Select a single point and a single edge (in any order).
- A constraint is added.
- Optionally keep creating constraints.
- To finish, right-click or press Esc, or start another geometry or constraint creation tool.
Run-once mode
- Do one of the following:
- Select a single point and a single edge (in any order).
- Select several points and a single edge (idem).
- Select a single point and several edges (idem).
- Invoke the tool as explained above.
- Depending on the selection one or more constraints are added.
Scripting
The constraint can be created from macros and from the Python console by using the following command:
Sketch.addConstraint(Sketcher.Constraint('PointOnObject',LineMoving,PointOfLineMoving,LineFixed))
-
Sketch
is a sketch object. -
LineMoving
is the number that designates the line, which contains the point that has to be moved on theLineFixed
(the line which is fixed). -
PointOfLineMoving
is the number of the vertex of lineLineMoving
, that has to be moved on theLineFixed
. -
LinedFixed
is the number of the line to be affixed on the pointPointOfLineMoving
.
The Sketcher scripting page explains how to identify the numbers that designate lines and points.
⏵ documentation index > Sketcher > Sketcher ConstrainPointOnObject
This page is retrieved from https://github.com/FreeCAD/FreeCAD-documentation/blob/main/wiki/Sketcher_ConstrainPointOnObject.md