Draft SelectPlane

From FreeCAD Documentation
Revision as of 00:07, 18 November 2018 by Vocx (talk | contribs) (How to use, including the presets that appear)

Draft SelectPlane

Menu location
Draft → Utilities → Select Plane
Workbenches
Draft, Arch
Default shortcut
W P
Introduced in version
-
See also
Draft SetWorkingPlaneProxy

Description

The Draft Workbench features a working plane system. A plane in the 3D view indicates where a Draft shape will be built. There are several methods to define the working plane:

  • From a selected face.
  • From three selected vertices.
  • From the current view.
  • From a preset: top, front, bottom, or lateral.
  • None, in which case the working plane is adapted automatically to the current view when you start a command, or to a face if you start drawing on an existing face.

How to use

  1. Press the SelectPlane button. If your button doesn't look like this, see this note.
  2. Select the offset, the grid spacing, and the main lines
  3. Select one of the presets: XY (top), XZ (front), YZ (side), View, or Auto.

Options

  • To set the workplane to existing geometry: select a face of an existing object in the 3D view, or, introduced in version 0.17, with CTRL pressed, 3 vertices on any object(s). Then press the SelectPlane button
  • Pressing the VIEW button will set the working plane as the view plane, perpendicular to the camera axis and passing through the (0,0,0) origin point.
  • Pressing the AUTO will unset any current working plane. The next 2D operations will be view-dependent.
  • You can also specify an offset value, which will set your working plane at a certain distance from the plane you select.
  • You can hide and show the grid with the shortcut GR

Scripting

Working plane objects can easily be created and manipulated in scripts and macros. You can create your own, and use them independently of the current Draft working plane.

Example:

import WorkingPlane
myPlane = WorkingPlane.plane()

You can also access the current Draft working plane:

import FreeCAD
draftPlane = FreeCAD.DraftWorkingPlane

To move or rotate the Draft working plane (see the WorkingPlane API page for available methods):

import FreeCAD
from FreeCAD import Vector
FreeCAD.DraftWorkingPlane.alignToPointAndAxis(Vector(0,0,0), Vector(1,1,1).normalize(), 17)

(note: a Draft command must have been issued to make grid adopt changes)

The working plane has a complete scripting API on its own, with convenience functions to position it and convert to/from placements.