Draft DelPoint

From FreeCAD Documentation
Jump to navigation Jump to search
This page is a translated version of the page Draft DelPoint and the translation is 12% complete.
Outdated translations are marked like this.
Other languages:
Deutsch • ‎English • ‎Türkçe • ‎español • ‎français • ‎italiano • ‎română • ‎svenska • ‎čeština • ‎русский
Arrow-left.svg Previous: Draft AddPoint.svg Add point

Draft DelPoint.svg Draft DelPoint

Menyplacering
Draft -> Remove Point
Arbetsbänk(ar)
Draft, Arch
Standard genväg
None
Introducerad i version
-
Se även
None


Beskrivning

The Draft DelPoint.svg Draft DelPoint tool allows you to remove points from already created Draft Wire.svg Draft Wires and Draft BSpline.svg Draft BSplines.

The counterpart to this tool is the Draft AddPoint.svg Draft AddPoint operation.

Usage

  1. Select a Draft Wire or a Draft BSpline. Note: the tool is disabled if no object is selected.
  2. Press the Draft DelPoint.svg Draft DelPoint button.
  3. Click a point on the object.
  4. Press Esc or the Close button to finish the operation; points already deleted will be gone.

This functionality is also available from the Draft Edit.svg Draft Edit tool.

Options

The options of this tool are described in Draft Edit.svg Draft Edit.

Skript

There is no programming interface available for the DelPoint tool, however, removing points is simple.

The Points attribute of a wire or spline is a list with the points that comprise that object; to remove points, overwrite this attribute with a shorter list of points. You can use methods like pop() to remove an element in the desired position in the list. Each point is defined by its FreeCAD.Vector, with units in millimeters.

Example:

import FreeCAD, Draft

p1 = FreeCAD.Vector(-1000, 400, 0)
p2 = FreeCAD.Vector(1500, -1500, 0)
p3 = FreeCAD.Vector(2200, 1000, 0)

wire = Draft.makeWire([p1, p2, p3])
points = wire.Points
points.pop(1)

wire.Points = points
FreeCAD.ActiveDocument.recompute()
Arrow-left.svg Previous: Draft AddPoint.svg Add point