Difference between revisions of "Draft Drawing"

From FreeCAD Documentation
Jump to navigation Jump to search
m (Languages in alphabetic order)
Line 1: Line 1:
{{GuiCommand|Name=Draft_Drawing|Workbenches=[[Draft Module|Draft]]|MenuLocation=Drafting Drawing}}
+
{{GuiCommand|Name=Draft_Drawing|Workbenches=[[Draft Module|Draft]]|MenuLocation=Drafting -> Drawing}}
  
====Description====
+
==Description==
  
This tool allows you to put selected objects on a svg [[Drawing Module|Drawing sheet]].
+
This tool allows you to put selected objects on a svg [[Drawing Module|Drawing sheet]]. If no sheet exists in the document, a default one will be created.
  
====Usage====
+
[[Image:Draft drawing example.jpg|400px]]
  
* Select objects you want to put on the drawing sheet.
+
==How to use==
 +
 
 +
# Select the objects you wish to put on a drawing sheet
 +
# Press the {{KEY|[[Image:Draft Drawing.png|16px]] [[Draft Drawing]]}} button
 +
 
 +
==Options==
 +
 
 +
* Select objects you want to put on the drawing sheet. The tool will work best with flat 2D objects from the [[Draft Module|Draft]] or [[Sketcher Module|Sketcher]] modules.
 
* In the same selection, add the page object you want to draw your objects to. If there is no existing page, a new one will be created. If you didn't select a page but there is at least one in the document, the first found one will be used to draw to.
 
* In the same selection, add the page object you want to draw your objects to. If there is no existing page, a new one will be created. If you didn't select a page but there is at least one in the document, the first found one will be used to draw to.
* The objects viewed on the Drawing page will take the hint scale and hint offset values of their host page. Be sure to set these values beforehand.
 
* You can change offset and scale values of objects anytime
 
* Set/adjust the Linewidth modifier. Higher value will result in thicker lines.
 
* Set/adjust the Textsize modifier. Higher values will result in bigger texts.
 
 
* If you selected an existing sheet, and the objects in the selection that are already on that sheet (for ex. for a "Rectangle" object there is already a "ViewRectangle" object on the sheet), they will be substitued. This allows you to simply select all the objects and send them to an existing page, which will simply be updated.
 
* If you selected an existing sheet, and the objects in the selection that are already on that sheet (for ex. for a "Rectangle" object there is already a "ViewRectangle" object on the sheet), they will be substitued. This allows you to simply select all the objects and send them to an existing page, which will simply be updated.
{{clear}}
+
 
 +
==Properties==
 +
 
 +
* {{PropertyData|Fill Style}}: For closed shapes, allows to specify one of the Default Draft fill styles, or use the shape color.
 +
* {{PropertyData|Font Size}}: Allows you to specify the font size of texts and dimensions.
 +
* {{PropertyData|Line Width}}: Allows you to specify the line width of viewed objects.
 +
 
 +
==Scripting==
 +
 
 +
The Draft Drawing tool can by used in [[macros]] and from the python console by using the following function:
 +
 
 +
'''makeDrawingView (object,page)''': adds a view of the given object to the given page. Returns the created view object.
 +
 
 +
Example:
 +
 
 +
import FreeCAD,Draft
 +
obj = FreeCAD.ActiveDocument.ActiveObject
 +
page = FreeCAD.ActiveDocument.Page
 +
Draft.makeDrawingView(obj,page)
 +
 
 
{{languages | {{es|Draft Drawing/es}} {{fr|Draft Drawing/fr}} {{it|Draft Drawing/it}} {{se|Draft Drawing/se}} }}
 
{{languages | {{es|Draft Drawing/es}} {{fr|Draft Drawing/fr}} {{it|Draft Drawing/it}} {{se|Draft Drawing/se}} }}

Revision as of 15:36, 22 August 2012

Draft Drawing.svg Draft_Drawing

Menu location
Drafting -> Drawing
Workbenches
Draft
Default shortcut
None
Introduced in version
-
See also
None


Description

This tool allows you to put selected objects on a svg Drawing sheet. If no sheet exists in the document, a default one will be created.

Draft drawing example.jpg

How to use

  1. Select the objects you wish to put on a drawing sheet
  2. Press the Draft Drawing.png Draft Drawing button

Options

  • Select objects you want to put on the drawing sheet. The tool will work best with flat 2D objects from the Draft or Sketcher modules.
  • In the same selection, add the page object you want to draw your objects to. If there is no existing page, a new one will be created. If you didn't select a page but there is at least one in the document, the first found one will be used to draw to.
  • If you selected an existing sheet, and the objects in the selection that are already on that sheet (for ex. for a "Rectangle" object there is already a "ViewRectangle" object on the sheet), they will be substitued. This allows you to simply select all the objects and send them to an existing page, which will simply be updated.

Properties

  • DataFill Style: For closed shapes, allows to specify one of the Default Draft fill styles, or use the shape color.
  • DataFont Size: Allows you to specify the font size of texts and dimensions.
  • DataLine Width: Allows you to specify the line width of viewed objects.

Scripting

The Draft Drawing tool can by used in macros and from the python console by using the following function:

makeDrawingView (object,page): adds a view of the given object to the given page. Returns the created view object.

Example:

import FreeCAD,Draft
obj = FreeCAD.ActiveDocument.ActiveObject
page = FreeCAD.ActiveDocument.Page
Draft.makeDrawingView(obj,page)
Available translations of this page: Flag-es.jpg Flag-fr.jpg Flag-it.jpg Template:Se