FreeCAD Logo FreeCAD 1.0
  • Engelska Afrikaans Arabiska Belarusian Katalanska Tjeckiska Tyska Grekiska Spanska Spanska Baskisk Finska Filippinska Franska Galiciska Kroatiska Ungerska Indonesiska Italienska Japanska Kabyliska Koreansk Litauiska Nederländska Norwegian Bokmal Polska Portugisiska Portugisiska Rumänska Ryska Slovakiska Slovenska Serbiska Svenska Turkiska Ukrainska Valencianska Vietnamesiska Kinesiska Kinesiska
  • Funktioner
  • Hämta
  • Blogg
  • Dokumentation
    Documentation index Kom igång Användardokumentation FreeCAD-manualen Dokumentation för arbetsytor Python coding documentation C++ coding documentation Övningar Frequently asked questions Privacy policy Om FreeCAD
  • Bidra
    Hur hjälper du till Sponsor Report a bug Make a pull request Jobs and funding Contribution guidelines Developers handbook Översättningar
  • Gemenskap
    Code of conduct Forum The FPA GitHub GitLab Codeberg Mastodon Matrix IRC IRC via Webchat Gitter Discord Reddit Twitter Facebook LinkedIn Calendar
  • ♥ Donate

Donate

$
SEPA Information
Ställ in din SEPA-banköverföring till:
Beneficiary: The FreeCAD project association
IBAN: BE04 0019 2896 4531
BIC/SWIFT: GEBABEBBXXX
Bankombud: BNP Paribas Fortis
Adress: Rue de la Station 64, 1360 Perwez, Belgium

While Stripe doesn't support monthly donations, you can still become a sponsor! Simply make a one-time donation equivalent to 12 months of support, and you'll gain access to the corresponding sponsoring tier. It's an easy and flexible way to contribute.

If you are not sure or not able to commit to a regular donation, but still want to help the project, you can do a one-time donation, of any amount.

Choose freely the amount you wish to donate one time only.

You can support FreeCAD by sponsoring it as an individual or organization through various platforms. Sponsorship provides a steady income for developers, allowing the FPA to plan ahead and enabling greater investment in FreeCAD. To encourage sponsorship, we offer different tiers, and unless you choose to remain anonymous, your name or company logo will be featured on our website accordingly.

from 1 USD / 1 EUR per month. You will not have your name displayed here, but you will have helped the project a lot anyway. Together, normal sponsors maintain the project on its feet as much as the bigger sponsors.

from 25 USD / 25 EUR per month. Your name or company name is displayed on this page.

from 100 USD / 100 EUR per month. Your name or company name is displayed on this page, with a link to your website, and a one-line description text.

from 200 USD / 200 EUR per month. Your name or company name and logo displayed on this page, with a link to your website and a custom description text. Companies that have helped FreeCAD early on also appear under Gold sponsors.

Instead of donating each month, you might find it more comfortable to make a one-time donation that, when divided by twelve, would give you right to enter a sponsoring tier. Don't hesitate to do so!

Choose freely the amount you wish to donate each month.

Please inform your forum name or twitter handle as a notein your transfer, or reach to us, so we can give you proper credits!

CAM Workbench
FEM Workbench
Index
Draft workbench icon

Introduction

Rit modulen är ett pågående arbete och är en ganska experimentell modul som har gjorts för att lägga till grundläggande 2d ritfunktionalitet till FreeCAD. Den är helt och hållet skriven i python, och är även tänkt att fungera som en presentation om hur mycket du kan utöka FreeCAD endast med hjälp av python, utan att ens röra källkoden.

Draft objects can be used for general drafting, similar to what can be done with Inkscape or AutoCAD. But they can also form the base for the creation of 3D objects in other workbenches. A Draft Wire may define the path of an Arch Wall, a Draft Polygon can be extruded with Part Extrude, etc. Many of the Draft modifier tools can be applied to 2D and 3D objects created with other workbenches as well. You can, for example, move a Sketch or create a Draft OrthoArray from a Part object.

The Draft Workbench also provides tools to define a working plane, a grid, and a snapping system to precisely control the position of geometry.

If your primary goal is the production of complex 2D drawings and DXF files, and you don't need 3D modelling, FreeCAD may not be the right choice for you. You may wish to consider a dedicated software program for technical drafting instead, such as LibreCAD or QCad.

The image shows the grid aligned with the XY-plane.
On the left, in white, several planar objects.
On the right a non-planar Draft Wire used as the Path Object of a Draft PathArray.

Drafting

  • Line: creates a straight line.
  • Polyline: creates a polyline (also called wire), a sequence of several connected line segments.
  • Fillet: creates a fillet, a rounded corner, or a chamfer, a straight edge, between two selected edges.
  • Arc Tools:
  • Arc: creates a circular arc from a center, a radius, a start angle and an aperture angle.
  • Arc From 3 Points: creates a circular arc from three points that define its circumference.
  • Circle: creates a circle from a center and a radius.
  • Ellipse: creates an ellipse from two points defining a rectangle in which the ellipse will fit.
  • Rectangle: creates a rectangle from two points.
  • Polygon: creates a regular polygon from a center and a radius.
  • B-Spline: creates a B-spline curve from several points.
  • Bézier Tools:
  • Cubic Bézier Curve: creates a Bézier curve of the third degree.
  • Bézier Curve: creates a Bézier curve from several points.
  • Point: creates a simple point.
  • Facebinder: creates a surface object from selected faces.
  • Shape From Text: creates a compound shape that represents a text string.
  • Hatch: creates hatches on the planar faces of a selected object.

Annotation

  • Text: creates a multi-line text at a given point.
  • Dimension: creates a linear dimension, a radial dimension or an angular dimension.
  • Label: creates a multi-line text with a 2-segment leader line and an arrow.
  • Annotation Styles: allows you to define styles that affect the visual properties of annotation-like objects.

Modification

  • Move: moves or copies selected objects from one point to another.
  • Rotate: rotates or copies selected objects around a center point by a given angle.
  • Scale: scales or copies selected objects around a base point.
  • Mirror: creates mirrored copies from selected objects.
  • Offset: offsets each segment of a selected object over a given distance, or creates an offset copy of the selected object.
  • Trimex: trims or extends a selected object.
  • Stretch: stretches objects by moving selected points.
  • Clone: creates linked copies, clones, of selected objects.
  • Array Tools:
  • Array: creates an orthogonal array from a selected object. It can optionally create a Link array.
  • Polar Array: creates an array from a selected object by placing copies along a circle. It can optionally create a Link array.
  • Circular Array: creates an array from a selected object by placing copies along concentric circles. It can optionally create a Link array.
  • Path Array: creates an array from a selected object by placing copies along a path.
  • Path Link Array: idem, but create a Link array instead of a regular array.
  • Point Array: creates an array from a selected object by placing copies at the points from a point compound.
  • Point Link Array: idem, but create a Link array instead of a regular array.
  • Edit: puts selected objects in Draft Edit mode. In this mode the properties of objects can be edited graphically.
  • Highlight Subelements: temporarily highlights selected objects, or the base objects of selected objects.
  • Join: joins Draft Lines and Draft Wires into a single wire.
  • Split: splits a Draft Line or Draft Wire at a specified point or edge.
  • Upgrade: upgrades selected objects.
  • Downgrade: downgrades selected objects.
  • Convert Wire/B-Spline: converts Draft Wires to Draft B-splines and vice versa.
  • Draft to Sketch: converts Draft objects to Sketcher Sketches and vice versa.
  • Set Slope: slopes selected Draft Lines or Draft Wires by increasing, or decreasing, the Z coordinate of all points after the first one.
  • Flip Dimension: rotates the dimension text of selected Draft Dimensions 180° around the dimension line.
  • Shape 2D View: creates 2D projections from selected objects.

Draft Tray

The Draft Tray allows selecting the working plane, defining style settings, toggling construction mode, and specifying the active layer or group.

  • Working Plane: defines the current Draft working plane. Also available in the menu: Draft → Utilities → Working Plane.
  • Set Style: sets the default style for new objects. Also available in the menu: Draft → Utilities → Set Style.
  • Toggle Construction Mode: switches Draft construction mode on or off. Also available in the menu: Draft → Utilities → Toggle Construction Mode.
  • AutoGroup: changes the active Draft Layer or, optionally, the active Std Group or group-like BIM object.

Draft Scale Widget

With the Draft Scale Widget the Draft annotation scale can be specified.

Draft Snap Widget

The Draft Snap Widget can be used as an alternative for the Draft Snap toolbar.

Draft Snap toolbar

With the Draft Snap toolbar the active snap options can be selected. The buttons belonging to active options stay depressed. For general information about snapping see: Draft Snap.

  • Snap Lock: enables or disables snapping globally.
  • Snap Endpoint: snaps to the endpoints of edges.
  • Snap Midpoint: snaps to the midpoint of edges.
  • Snap Center: snaps to the center point of faces and circular edges, and to the DataPlacement point of Draft WorkingPlaneProxies and Arch BuildingParts.
  • Snap Angle: snaps to the special cardinal points on circular edges, at multiples of 30° and 45°.
  • Snap Intersection: snaps to the intersection of two edges, and (introduced in 1.1) the intersection of a face and an edge.
  • Snap Perpendicular: snaps to the perpendicular points on faces (introduced in 0.21) and edges.
  • Snap Extension: snaps to an imaginary line that extends beyond the endpoints of straight edges.
  • Snap Parallel: snaps to an imaginary line parallel to straight edges.
  • Snap Special: snaps to special points defined by the object.
  • Snap Near: snaps to the nearest point on faces and edges.
  • Snap Ortho: snaps to imaginary lines that cross the previous point at multiples of 45°.
  • Snap Grid: snaps to the intersections of grid lines.
  • Snap Working Plane: projects snap points onto the current working plane.
  • Snap Dimensions: shows temporary X and Y dimensions.
  • Toggle Grid: changes the visibility of the grid.

Draft Utilities toolbar

  • Manage Layers: allows to manage the layers in a document. introduced in 0.21
  • New Named Group: creates a named Std Group and adds objects to that group.
  • Select Group: selects the contents of Std Groups or group-like BIM objects.
  • Add to Layer: adds objects to a layer, or removes them from any layer. introduced in 1.1
  • Add to Group: adds objects to a Std Group. It can also ungroup objects.
  • Add to Construction Group: adds objects to the Draft construction group.
  • Toggle Wireframe: switches the VyDisplay Mode property of selected objects between Flat Lines and Wireframe.
  • Working Plane Proxy: creates a working plane proxy to save the current Draft working plane.

Additional tools

The Draft → Utilities menu contains several tools. Most of them can also be accessed from toolbars or the Draft Tray and have already been mentioned above. For the following tools this is not the case:

  • Apply Current Style: applies the current style settings to selected objects.
  • New Layer: creates a Draft Layer.
  • Heal: heals problematic Draft objects found in very old files.
  • Show Snap Toolbar: shows the Draft Snap toolbar.

Gemensamt beteende

  • Snäpp: tillåter dig att placera nya punkter på speciella platser på existerande objekt
  • Begränsning: Tillåter att nya punkter placeras horisontellt eller vertikalt i relation till tidigare punkter
  • Konstruktionsläge: Tillåter dig att skilja viss geometri åt från resten, för att lätt kunna stänga på/av
  • Arbetsplan: Alla skisskommandon kan användas på valfritt plani i 3D rymden. Det gällande arbetsplanet kan konfigureras på ett lätt sätt

Tree View context menu

The following additional options are available in the Tree View context menu:

Default options

For most Draft objects the following option is available:

  • Edit: edits the object. Depending on the object type either Draft Edit or a dedicated edit solution is used. introduced in 0.21

If there is an active document the context menu contains an additional sub-menu:

  • Utilities: a subset of the tools available in the main Draft Utilities menu.

Layer container options

For a Draft LayerContainer these additional options are available:

  • Add New Layer: adds a new layer to the current document.
  • Reassign Properties of All Layers: removes overrides from objects in all layers. introduced in 1.1
  • Merge Layer Duplicates: merges all layers with the same base label.

Layer options

For a Draft Layer these additional options are available:

  • Activate Layer: activates the selected layer.
  • Reassign Properties of Layer: removes overrides from objects in the layer. introduced in 1.1
  • Select Layer Contents: selects the objects inside the selected layer.

Text options

For a Draft Text and a Draft Label that contains one or more hyperlinks, to a local or remote file or an URL, this additional option is available:

  • Open Links: the hyperlinks are opened in the appropriate application (as defined by the OS). There is a warning in the case of multiple hyperlinks. introduced in 1.0

Wire options

For a Draft Line and a Draft Wire this additional option is available:

  • Flatten: flattens the wire on the current Draft working plane.

Working plane proxy options

For a Draft WorkingPlaneProxy these additional options are available:

  • Save Camera Position: updates the VyView Data property of the working plane proxy with the current 3D View camera settings.
  • Save Visibility of Objects: updates the VyVisibility Map property of the working plane proxy with the current visibility state of objects in the document.

3D View context menu

The following additional options are available in the 3D View context menu:

Default options

If there is an active document the context menu contains one additional sub-menu:

  • Utilities: a subset of the tools available in the main Draft Utilities menu.

Text options

See above.

Obsolete tools

  • Array: creates an orthogonal array from a selected object. The created array can be turned into a polar array or a circular array by changing its DataArray Type property. Not available in 0.21 and above.
  • Drawing: inserts views of selected objects into a drawing page. Not available in 0.21 and above.
  • Toggle continue mode: switches continue mode on or off. Not available in 1.0 and above.

Preferences

  • Preferences: general preferences for the Draft Workbench.
  • Import Export Preferences: preferences available for importing from and exporting to different file formats.

Import & export

Detta är funktioner för att öppna, importera eller exportera andra filformat. Öppna kommet att öppna ett nytt dokument med filens innehåll, medan importera kommer att lägga till filinnehållet till det nuvarande dokumentet. Exportera kommer att spara de valda objekten till en fil. Om inget är valt, så kommer alla objekt att exporteras. Var uppmärksam på att eftersom tanken med Ritmodulen är att arbeta med 2d objekt, så fokuserar dessa importerare endast på 2d objekt, och, fastän DXF och OCA formaten stödjer objektdefinitioner i 3D rymden (objekt är inte nödvändigtvis platta), så kommer de inte att importera volymetriska objekt som nät, 3D ytor, etc, utan snarare linjer, cirklar, text eller flata former. För närvarande så stöds följande filformat:

  • Autodesk .DXF: Importerar och exporterar DXF filer som har skapats med andra CAD applikationer
  • SVG (som geometri): Importerar och exporterar SVG filer som har skapats med vektorbaserade ritapplikationer
  • Open Cad format .OCA: Importerar och exporterar OCA/GCAD files, ett potentiellt nytt öppet CAD filformat
  • Airfoil Data Format .DAT Importerar DAT filer som beskriver Vingprofiler

Unit tests

See also: Test Workbench.

To run the unit tests of the workbench execute the following from the operating system terminal:

freecad -t TestDraft

API

Se Skiss API sidan för en komplett beskrivning av Skissfunktionerna som du kan använda i skript och makron

The workbench includes a module to create samples of all objects in a new document.

Use this to test that all objects are produced correctly:

import drafttests.draft_test_objects as dto
doc = dto.create_test_file()

Inspecting the code of this module can help to understand the programming interface.

Tutorials

Tutorials

  • Draft tutorial
  • Draft ShapeString tutorial


Raytracing_Workbench/sv
Robot_Workbench/sv
Index

Denna sida hämtas från https://wiki.freecad.org/Draft_Workbench

Kontakta oss!
Forum GitHub Mastodon Matrix IRC Gitter.im Discord Reddit Twitter Facebook LinkedIn

© The FreeCAD Team. Homepage image credits (top to bottom): ppemawm, r-frank, epileftric, regis, rider_mortagnais, bejant.

This project is supported by: , KiCad Services Corp. och andra sponsorer

GitHubImprove this page on GitHub