Part Plane: Difference between revisions

From FreeCAD Documentation
mNo edit summary
(Marked this version for translation)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
<languages/>
<languages/>
{{UnfinishedDocu{{#translation:}}}}
<translate>
<translate>


Line 17: Line 16:
|Name=Part Plane
|Name=Part Plane
|MenuLocation=Part → [[Part_Primitives|Create primitives]] → Plane
|MenuLocation=Part → [[Part_Primitives|Create primitives]] → Plane
|Workbenches=[[Part_Workbench|Part]]
|Workbenches=[[Part_Workbench|Part]], [[OpenSCAD_Workbench|OpenSCAD]]
|SeeAlso=[[Part_Primitives|Part Primitives]]
|SeeAlso=[[Part_Primitives|Part Primitives]]
}}
}}
Line 32: Line 31:
== Usage == <!--T:8-->
== Usage == <!--T:8-->


<!--T:24-->
See [[Part_Primitives#Usage|Part Primitives]].
See [[Part_Primitives#Usage|Part Primitives]].


== Example ==
== Example == <!--T:25-->


<!--T:26-->
[[Image:Part_Plane_Scripting_Example.png|thumb|Part Plane from the scripting example]]
[[Image:Part_Plane_Scripting_Example.png|thumb|Part Plane from the scripting example]]


<!--T:27-->
A Part Plane object created with the [[#Scripting|scripting example]] below is shown here.
A Part Plane object created with the [[#Scripting|scripting example]] below is shown here.


== Properties == <!--T:16-->
== Properties == <!--T:16-->


<!--T:28-->
See also: [[Property_editor|Property editor]].
See also: [[Property_editor|Property editor]].


<!--T:29-->
A Part Plane object is derived from a [[Part_Feature|Part Feature]] object and inherits all its properties. It also has the following additional properties:
A Part Plane object is derived from a [[Part_Feature|Part Feature]] object and inherits all its properties. It also has the following additional properties:


=== Data === <!--T:17-->
=== Data === <!--T:17-->


<!--T:30-->
{{TitleProperty|Attachment}}
{{TitleProperty|Attachment}}


<!--T:31-->
The object has the same attachment properties as a [[Part_Part2DObject#Data|Part Part2DObject]].
The object has the same attachment properties as a [[Part_Part2DObject#Data|Part Part2DObject]].


Line 59: Line 65:
* {{PropertyData|Width|Length}}: The width of the plane. This is the dimension in its Y direction. The default is {{Value|10mm}}.
* {{PropertyData|Width|Length}}: The width of the plane. This is the dimension in its Y direction. The default is {{Value|10mm}}.


== Scripting ==
== Scripting == <!--T:32-->


<!--T:33-->
See also: [https://freecad.github.io/SourceDoc/ Autogenerated API documentation], [[Part_scripting|Part scripting]] and [[FreeCAD_Scripting_Basics|FreeCAD Scripting Basics]].
See also: [https://freecad.github.io/SourceDoc/ Autogenerated API documentation], [[Part_scripting|Part scripting]] and [[FreeCAD_Scripting_Basics|FreeCAD Scripting Basics]].


<!--T:34-->
A Part Plane can be created with the {{Incode|addObject()}} method of the document:
A Part Plane can be created with the {{Incode|addObject()}} method of the document:


Line 71: Line 79:
<translate>
<translate>


<!--T:35-->
* Where {{Incode|"myPlane"}} is the name for the object.
* Where {{Incode|"myPlane"}} is the name for the object.
* The function returns the newly created object.
* The function returns the newly created object.


<!--T:36-->
Example:
Example:



Latest revision as of 10:03, 3 March 2022

Part Plane

Menu location
Part → Create primitives → Plane
Workbenches
Part, OpenSCAD
Default shortcut
None
Introduced in version
-
See also
Part Primitives

Description

A Part Plane is a parametric rectangular plane that can be created with the Part Primitives command. In the coordinate system defined by its DataPlacement property, the plane lies on the XY plane with its front left corner at the origin, and its front edge parallel to the X axis.

Usage

See Part Primitives.

Example

Part Plane from the scripting example

A Part Plane object created with the scripting example below is shown here.

Properties

See also: Property editor.

A Part Plane object is derived from a Part Feature object and inherits all its properties. It also has the following additional properties:

Data

Attachment

The object has the same attachment properties as a Part Part2DObject.

Plane

  • DataLength (Length): The length of the plane. This is the dimension in its X direction. The default is 10mm.
  • DataWidth (Length): The width of the plane. This is the dimension in its Y direction. The default is 10mm.

Scripting

See also: Autogenerated API documentation, Part scripting and FreeCAD Scripting Basics.

A Part Plane can be created with the addObject() method of the document:

plane = FreeCAD.ActiveDocument.addObject("Part::Plane", "myPlane")
  • Where "myPlane" is the name for the object.
  • The function returns the newly created object.

Example:

import FreeCAD as App

doc = App.activeDocument()

plane = doc.addObject("Part::Plane", "myPlane")
plane.Length = 4
plane.Width = 8
plane.Placement = App.Placement(App.Vector(1, 2, 3), App.Rotation(20, 75, 60))

doc.recompute()