Draft SelectPlane: Difference between revisions
(Editing Options...) |
(Editing Options...) |
||
Line 68: | Line 68: | ||
<!--T:5--> |
<!--T:5--> |
||
* Pressing any of the buttons will finish the command and close the task panel. |
|||
* Press the {{Button|[[Image:View-top.svg|16px]] Top (XY)}} button to align the working plane to the XY plane of the global coordinate system. |
|||
* Press the {{Button|[[Image:View- |
* Press the {{Button|[[Image:View-top.svg|16px]] Top (XY)}} button to align the working plane with the XY plane of the global coordinate system. |
||
* Press the {{Button|[[Image:View- |
* Press the {{Button|[[Image:View-front.svg|16px]] Front (XZ)}} button to align the working plane with the XZ plane of the global coordinate system. |
||
* Press the {{Button|[[Image:View- |
* Press the {{Button|[[Image:View-right.svg|16px]] Side (YZ)}} button to align the working plane with the YZ plane of the global coordinate system. |
||
* Press the {{Button|[[Image:View- |
* Press the {{Button|[[Image:View-isometric.svg|16px]] Align to view}} button to align the working plane with the current [[3D_view|3D view]], perpendicular to the camera axis and with its origin matching the origin of the global coordinate system (if the {{MenuCommand|Center plane on view}} checkbox is unchecked). |
||
* Press the {{Button|[[Image:View-axonometric.svg|16px]] Automatic}} button to automatically align the working plane with the current [[3D_view|3D view]] whenever a Draft command requiring point input is started. This is equivalent to pressing the {{Button|[[Image:View-isometric.svg|16px]] Align to view}} button before using the command. |
|||
* Change the {{MenuCommand|Offset}} to place the working plane at a perpendicular distance from the selected plane. |
* Change the {{MenuCommand|Offset}} to place the working plane at a perpendicular distance from the selected plane. |
||
* Check the {{MenuCommand|Center plane on view}} checkbox to put the origin of the working plane in the center of to the current [[3D_view|3D view]]. This option only makes sense if the {{Button|[[Image:View-isometric.svg|16px]] Align to view}} button is used. |
* Check the {{MenuCommand|Center plane on view}} checkbox to put the origin of the working plane in the center of to the current [[3D_view|3D view]]. This option really only makes sense if the {{Button|[[Image:View-isometric.svg|16px]] Align to view}} button is used. |
||
* Select a vertex in the 3D view and press the {{Button|[[Image:Draft_Move.svg|16px]] Move working plane}} button to move the working plane so that its origin matches the position of the selected vertex. |
|||
Revision as of 10:32, 25 July 2021
Draft SelectPlane |
Menu location |
---|
Draft → Utilities → Select Plane |
Workbenches |
Draft, Arch |
Default shortcut |
W P |
Introduced in version |
- |
See also |
Draft WorkingPlaneProxy, Draft ToggleGrid |
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, or side.
- 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.
Different working planes can be set on which to draw shapes
Usage
The SelectPlane button is present in the Draft Tray toolbar, which only appears in the Draft and Arch workbenches.
Without element selected
- Press the SelectPlane button, or use Draft → Utilities → SelectPlane from the top menu, or the keyboard shortcut W then P
- Select the offset, the grid spacing, and the main lines
- Select one of the presets: XY (top), XZ (front), YZ (side), View, or Auto.
Once the plane is set, the button will change to indicate the active plane Top, Front, Side, Auto, d(0.0,-1.0,0.0).
You can show and hide the grid with the shortcut G R.
With element selected
- Select a face of an existing object in the 3D view, or hold Ctrl and select three vertices of any object. introduced in version 0.17
- Press the SelectPlane button, or right click and select Utilities → SelectPlane.
The plane will be created aligned to the face of the object, or to the plane defined by the three vertices.
Options
- Pressing any of the buttons will finish the command and close the task panel.
- Press the Top (XY) button to align the working plane with the XY plane of the global coordinate system.
- Press the Front (XZ) button to align the working plane with the XZ plane of the global coordinate system.
- Press the Side (YZ) button to align the working plane with the YZ plane of the global coordinate system.
- Press the Align to view button to align the working plane with the current 3D view, perpendicular to the camera axis and with its origin matching the origin of the global coordinate system (if the Center plane on view checkbox is unchecked).
- Press the Automatic button to automatically align the working plane with the current 3D view whenever a Draft command requiring point input is started. This is equivalent to pressing the Align to view button before using the command.
- Change the Offset to place the working plane at a perpendicular distance from the selected plane.
- Check the Center plane on view checkbox to put the origin of the working plane in the center of to the current 3D view. This option really only makes sense if the Align to view button is used.
- Select a vertex in the 3D view and press the Move working plane button to move the working plane so that its origin matches the position of the selected vertex.
- Set the "Grid spacing" value to define the space between each line in the grid.
- Set the "Grid size" value to define the overall extension of the grid plane.
- Set the "Main line every" value to draw a slightly thicker line in the grid at the set value. For example, if the grid spacing is 0.5 m, and there is a main line every 20 lines, there will be slightly thicker line every 10 m.
- Press Esc or the Close button to abort the current command.
- The grid displays an additional border with mainline spacing indicated in the bottom left corner introduced in version 0.19. This can be disabled via Edit → Preferences Draft → Grid and snapping → Show grid border.
Scripting
See also: Draft API and FreeCAD Scripting Basics. See the WorkingPlane API.
Working plane objects can easily be created and manipulated in macros and from the Python console.
You can access the current Draft working plane, and apply transformations to it:
import FreeCAD as App
import FreeCADGui as Gui
workplane = App.DraftWorkingPlane
v1 = App.Vector(0, 0, 0)
v2 = App.Vector(1, 1, 1).normalize()
workplane.alignToPointAndAxis(v1, v2, 17)
Gui.Snapper.toggleGrid()
Gui.Snapper.toggleGrid()
A Draft command must be issued after changing the working plane to update the visible grid, for example, Line, or just ToggleGrid.
You can create your own planes, and use them independently of the current working plane. This is useful if you need to make calculations or projections in these other planes.
import WorkingPlane
my_plane = WorkingPlane.plane()
v1 = App.Vector(0, 0, 0)
v2 = App.Vector(1, 1, 1).normalize()
my_plane.alignToPointAndAxis(v1, v2, 17)
projection = my_plane.projectPoint(App.Vector(10, 15, 2))
print(projection)
To display a new grid use a new tracker object. First set up the normal working plane as you need, then create a new tracker object, then set it to the current plane, and then you can turn it on or off.
import FreeCAD as App
import DraftTrackers
App.DraftWorkingPlane.alignToPointAndAxis(App.Vector(0, 0, 0),
App.Vector(1, 0, 0),
0)
my_grid = DraftTrackers.gridTracker()
my_grid.set()
my_grid.on()
my_grid.off()
This grid is merely a visual aid and doesn't allow snapping.
To have the possibility of switching quickly to different grids, in different positions, you should create a Working plane proxy.
- Drafting: Line, Polyline, Fillet, Arc, Arc by 3 points, Circle, Ellipse, Rectangle, Polygon, B-spline, Cubic Bézier curve, Bézier curve, Point, Facebinder, ShapeString, Hatch
- Annotation: Text, Dimension, Label, Annotation styles, Annotation scale
- Modification: Move, Rotate, Scale, Mirror, Offset, Trimex, Stretch, Clone, Array, Polar array, Circular array, Path array, Path link array, Point array, Point link array, Edit, Subelement highlight, Join, Split, Upgrade, Downgrade, Wire to B-spline, Draft to sketch, Set slope, Flip dimension, Shape 2D view
- Draft Tray: Select plane, Set style, Toggle construction mode, AutoGroup
- Snapping: Snap lock, Snap endpoint, Snap midpoint, Snap center, Snap angle, Snap intersection, Snap perpendicular, Snap extension, Snap parallel, Snap special, Snap near, Snap ortho, Snap grid, Snap working plane, Snap dimensions, Toggle grid
- Miscellaneous: Apply current style, Layer, Manage layers, Add a new named group, Move to group, Select group, Add to construction group, Toggle normal/wireframe display, Create working plane proxy, Heal, Show snap toolbar
- Additional: Constraining, Pattern, Preferences, Import Export Preferences, DXF/DWG, SVG, OCA, DAT
- Context menu:
- Layer container: Merge layer duplicates, Add new layer
- Layer: Activate this layer, Select layer contents
- Text: Open hyperlinks
- Wire: Flatten
- Working plane proxy: Write camera position, Write objects state
- Getting started
- Installation: Download, Windows, Linux, Mac, Additional components, Docker, AppImage, Ubuntu Snap
- Basics: About FreeCAD, Interface, Mouse navigation, Selection methods, Object name, Preferences, Workbenches, Document structure, Properties, Help FreeCAD, Donate
- Help: Tutorials, Video tutorials
- Workbenches: Std Base, Arch, Assembly, CAM, Draft, FEM, Inspection, Mesh, OpenSCAD, Part, PartDesign, Points, Reverse Engineering, Robot, Sketcher, Spreadsheet, Surface, TechDraw, Test Framework
- Hubs: User hub, Power users hub, Developer hub