Difference between revisions of "TechDraw Dimension Length"

From FreeCAD Documentation
Jump to: navigation, search
m ([[ | ]])
 
(10 intermediate revisions by 4 users not shown)
Line 2: Line 2:
 
<translate>
 
<translate>
 
<!--T:23-->
 
<!--T:23-->
{{Docnav|[[TechDraw_ClipMinus|ClipMinus]]|[[TechDraw_Dimension_Horizontal|New Horizontal]]|[[TechDraw_Module|TechDraw]]|IconL=techdraw-clipminus.svg|IconC=Workbench_TechDraw.svg|IconR=Techdraw_Dimension_Horizontal.png}}
+
{{Docnav
 +
|[[TechDraw_ClipMinus|ClipMinus]]
 +
|[[TechDraw_Dimension_Horizontal|New Horizontal]]
 +
|[[TechDraw_Module|TechDraw]]
 +
|IconL=techdraw-clipminus.svg
 +
|IconC=Workbench_TechDraw.svg
 +
|IconR=Techdraw_Dimension_Horizontal.png
 +
}}
  
 
<!--T:1-->
 
<!--T:1-->
Line 42: Line 49:
 
<!--T:26-->
 
<!--T:26-->
 
If you want to keep a TechDraw view with dimensions that won't break, you need to dimension an object that won't change.
 
If you want to keep a TechDraw view with dimensions that won't break, you need to dimension an object that won't change.
* Select the object that you want to project, then switch to the [[Part Workbench|Part Workbench]] and use {{MenuCommand|Part → [[Image:Part_CreateSimpleCopy.svg|16px]] [[Part CreateSimpleCopy|Create simple copy]]}}. This will create a single object that is not parametric, that is, no longer editable.
+
* Select the object that you want to project, then switch to the [[Part Workbench|Part Workbench]] and use {{MenuCommand|Part → [[Image:Part_SimpleCopy.svg|16px]] [[Part SimpleCopy|Create simple copy]]}}. This will create a single object that is not parametric, that is, no longer editable.
 
* Select this copy, then use [[TechDraw NewView|TechDraw NewView]], and add the desired dimensions.
 
* Select this copy, then use [[TechDraw NewView|TechDraw NewView]], and add the desired dimensions.
 
* If the original 3D model is modified, the modifications won't affect the simple copy, nor the dimensions in the TechDraw view.
 
* If the original 3D model is modified, the modifications won't affect the simple copy, nor the dimensions in the TechDraw view.
Line 49: Line 56:
  
 
=== Data === <!--T:16-->
 
=== Data === <!--T:16-->
 +
{{Properties_Title|Base}}
 
* {{PropertyData|X}}: Horizontal position of the dimension text relative to the View.
 
* {{PropertyData|X}}: Horizontal position of the dimension text relative to the View.
 
* {{PropertyData|Y}}: Vertical position of the dimension text relative to the View.
 
* {{PropertyData|Y}}: Vertical position of the dimension text relative to the View.
* {{PropertyData|FormatSpec}}: Allows additional text to be added to the dimension text. Dimension value will replace %.2f (or other valid [https://en.wikipedia.org/wiki/Printf_format_string printf] format specifier).
 
 
* {{PropertyData|Type}}: Length,radius,diameter, etc. Not normally manipulated by the end user.  
 
* {{PropertyData|Type}}: Length,radius,diameter, etc. Not normally manipulated by the end user.  
 
* {{PropertyData|MeasureType}}: {{TRUE}} - based on 3D geometry or "Projected" - based on the drawing. Not normally manipulated directly by the end user.
 
* {{PropertyData|MeasureType}}: {{TRUE}} - based on 3D geometry or "Projected" - based on the drawing. Not normally manipulated directly by the end user.
 +
* {{PropertyData|TheoreticalExact}}: Specifies a theoretically exact (or basic) dimension.
 +
::{{FALSE}} - a common dimension by default, possibly with tolerances.
 +
::{{TRUE}} - a theoretical value. As such, it shall not bear any tolerances. Marked by a frame around the value.
 
* {{PropertyData|OverTolerance}}: The amount by which the piece may be larger than the Dimension shown.
 
* {{PropertyData|OverTolerance}}: The amount by which the piece may be larger than the Dimension shown.
 
* {{PropertyData|UnderTolerance}}: The amount by which the piece may be smaller than the Dimension shown.
 
* {{PropertyData|UnderTolerance}}: The amount by which the piece may be smaller than the Dimension shown.
* {{PropertyData|Arbitrary}}: {{TRUE}} - ignore actual value and display FormatSpec as value. {{FALSE}} - use actual value.
+
* {{PropertyData|Inverted}}: Marks whether the dimension represents a common or an inverted value.
 +
::{{FALSE}} - the ordinary value is used. For length it is a positive number, for angle the oblique value (0° - 180°).
 +
::{{TRUE}} - the inverted value is used. For length a negative number, for angle the reflex value (180° - 360°).
 +
 
 +
<!--T:27-->
 +
{{Properties_Title|Format}}
 +
* {{PropertyData|FormatSpec}}: Allows additional text to be added to the dimension text.
 +
::Dimension value will replace the <code>%.2f</code> part of text (or any other valid format specifier - see [https://en.wikipedia.org/wiki/Printf_format_string printf]).
 +
* {{PropertyData|Arbitrary}}: Specifies, whether treat '''FormatSpec''' as a template or an actual text.
 +
::{{FALSE}} - replace the format specifier with the actual dimensional value.
 +
::{{TRUE}} - ignore the dimensional value and display exactly '''FormatSpec''' as value.
  
 
=== View === <!--T:17-->
 
=== View === <!--T:17-->
 +
{{Properties_Title|Base}}
 +
* {{PropertyView|Visibility}}: Sets whether the dimension is visible. {{TRUE}} - visible, {{FALSE}} - hidden.
 +
{{Properties_Title|Dim Format}}
 
* {{PropertyView|Font}}: The name of the font to use for the dimension text.
 
* {{PropertyView|Font}}: The name of the font to use for the dimension text.
* {{PropertyView|Fontsize}}: Dimension text size in mm.
+
* {{PropertyView|FontSize}}: Dimension text size in mm.
 
* {{PropertyView|LineWidth}}: Dimension line weight.  
 
* {{PropertyView|LineWidth}}: Dimension line weight.  
 
* {{PropertyView|Color}}: Color for lines and text.
 
* {{PropertyView|Color}}: Color for lines and text.
 +
* {{PropertyView|StandardAndStyle}}: Specifies the standard (and the style of it) according to which the dimension is drawn:
 +
::<code>ISO Oriented</code> - drawn according to ISO 129.1 (international standard), text is rotated to be parallel with the dimension line tangent.
 +
::<code>ISO Referencing</code> - drawn in compliance with ISO-129.1, text is always horizontal, above the shortest possible reference line.
 +
::<code>ASME Inlined</code> - drawn according to ASME Y14.5M (US standard), text is horizontal, inserted in a break within the dimension line or arc.
 +
::<code>ASME Referencing</code> - drawn in compliance with ASME Y14.5M, text is horizontal, short reference line is attached to one side's vertical center.
 +
* {{PropertyView|RenderingExtent}}: Rather universal property specifying how much space the dimension drawing may take up:
 +
::<code>None</code> - no lines or arrows are drawn, only the bare dimension value is displayed.
 +
::<code>Minimal</code> - for lengths and angles a single headed line connecting the dimensional value and the end point's ''virtual extension line'' is drawn. The extension line itself is not added.
 +
::Diameters are rendered following <code>Confined</code> extent, radii following <code>Reduced</code> extent.
 +
::<code>Confined</code> - for lengths and angles a double headed line (or arc) connecting the start and end point's ''virtual extension lines'' is drawn, though the extension lines themselves are not added.
 +
::Diameters are drawn with a minimal single headed line from dimensional value to the closest point on circle, radii as with <code>Reduced</code> extent.
 +
::<code>Reduced</code> - for lengths and angles a single headed line connecting the dimensional value and the end point's ''extension line'' is drawn along with the extension line itself.
 +
::Diameters are drawn with a single headed line from the center to the closest point on circle, radii with a minimal single headed line from dimensional value to the closest arc point.
 +
::<code>Normal</code> - the default value. For lengths and angles a double headed line (or arc) connecting the start and end point's ''extension lines'' is drawn, the extension lines themselves as well.
 +
::Diameters are drawn as double headed lines striking the center and connecting the closest and farthest points on the circle.
 +
::Radii are drawn as a single headed line from center to the closest arc point.
 +
::<code>Expanded</code> - Only diameters support this value, rendering them in a horizontal or vertical length-like way. Other dimension types are rendered as with <code>Normal</code> extent.
 +
* {{PropertyView|FlipArrowheads}}: By default the value ''inside'' the dimension line/arc means the arrows pointing ''outwards''. If placed ''outside'' the dimension line/arc, the arrows point ''inwards'' the dimension line/arc.
 +
::{{FALSE}} - Let the direction of arrows to be selected automatically according to the rule above.
 +
::{{TRUE}} - Override the automatically chosen direction and force the opposite one.
 +
 +
==Standard and Style== <!--T:28-->
 +
 +
<!--T:29-->
 +
For a quick preview and presentation of the 4 basic Standard And Style differences, please see the picture below (from https://forum.freecadweb.org/viewtopic.php?f=35&t=39571):
 +
 +
<!--T:30-->
 +
[[File:TechDraw Dimension standardization.png]]
  
 
==Scripting== <!--T:6-->
 
==Scripting== <!--T:6-->
Line 86: Line 137:
 
<!--T:20-->
 
<!--T:20-->
 
* '''Edge selection'''. Edges can be difficult to select.  You can adjust the selection area for edges using the parameter "/Mod/TechDraw/General/EdgeFuzz" (see [[Std_DlgParameter|Std_DlgParameter]]).  This is a dimension-less number. The default is 10.0.  Values in the 20-30 range will make it noticeably easier to select edges.  Large numbers will cause overlaps with other drawing elements.  
 
* '''Edge selection'''. Edges can be difficult to select.  You can adjust the selection area for edges using the parameter "/Mod/TechDraw/General/EdgeFuzz" (see [[Std_DlgParameter|Std_DlgParameter]]).  This is a dimension-less number. The default is 10.0.  Values in the 20-30 range will make it noticeably easier to select edges.  Large numbers will cause overlaps with other drawing elements.  
* '''Decimal places'''. Dimensions use the global decimal places setting by default. This can be changed via [[TechDraw_Preferences|preferences]] or by changing the FormatSpec property.   
+
* '''Decimal places'''. Dimensions use the global decimal places setting by default. This can be changed via [[TechDraw_Preferences#Dimensions|preferences]] or by changing the FormatSpec property.   
  
  
 
<!--T:24-->
 
<!--T:24-->
{{Docnav|[[TechDraw_ClipMinus|ClipMinus]]|[[TechDraw_Dimension_Horizontal|New Horizontal]]|[[TechDraw_Module|TechDraw]]|IconL=techdraw-clipminus.svg|IconC=Workbench_TechDraw.svg|IconR=Techdraw_Dimension_Horizontal.png}}
+
{{Docnav
 +
|[[TechDraw_ClipMinus|ClipMinus]]
 +
|[[TechDraw_Dimension_Horizontal|New Horizontal]]
 +
|[[TechDraw_Module|TechDraw]]
 +
|IconL=techdraw-clipminus.svg
 +
|IconC=Workbench_TechDraw.svg
 +
|IconR=Techdraw_Dimension_Horizontal.png
 +
}}
  
 
<!--T:21-->
 
<!--T:21-->

Latest revision as of 22:30, 15 October 2019

Other languages:
Deutsch • ‎English • ‎français • ‎italiano • ‎română • ‎русский

TechDraw Dimension Length.svg TechDraw Dimension Length

Menu location
TechDraw → Dimension Length
Workbenches
TechDraw
Default shortcut
None
Introduced in version
-
See also
TechDraw Dimension Horizontal, TechDraw Dimension Vertical


Description

The Dimension Length tool adds a linear dimension to a View. The dimension may be between the distance between two vertices, the length of one edge or the distance between 2 edges. The distance will initially be the projected distance (ie as shown on the drawing), but this may be changed to the actual 3D distance using the TechDraw Dimension Link.svg Link Dimension tool.

TechDraw Dimension Length example.png

Length dimension taken from two arbitrary nodes of the view


How to use

  1. Select the points or edge which define your measurement.
  2. Press the TechDraw Dimension Length.png Dimension Length button
  3. A dimension will be added to the View. The dimension may be dragged to the desired position.

Limitations

Dimension objects are vulnerable to the "topological naming problem". This means that if you modify the 3D geometry the faces and edges of the model may be renamed internally; if a dimension is attached to an edge that is then modified, the dimension may break. In general, it is not possible to keep the projected 2D dimensions synchronized with the actual 3D objects.

Therefore, it is recommended that dimensions be added when the 3D model is no longer being modified.

Workaround

If you want to keep a TechDraw view with dimensions that won't break, you need to dimension an object that won't change.

  • Select the object that you want to project, then switch to the Part Workbench and use Part → Part SimpleCopy.svg Create simple copy. This will create a single object that is not parametric, that is, no longer editable.
  • Select this copy, then use TechDraw NewView, and add the desired dimensions.
  • If the original 3D model is modified, the modifications won't affect the simple copy, nor the dimensions in the TechDraw view.

Properties

Data

Base

  • DATAX: Horizontal position of the dimension text relative to the View.
  • DATAY: Vertical position of the dimension text relative to the View.
  • DATAType: Length,radius,diameter, etc. Not normally manipulated by the end user.
  • DATAMeasureType: True - based on 3D geometry or "Projected" - based on the drawing. Not normally manipulated directly by the end user.
  • DATATheoreticalExact: Specifies a theoretically exact (or basic) dimension.
False - a common dimension by default, possibly with tolerances.
True - a theoretical value. As such, it shall not bear any tolerances. Marked by a frame around the value.
  • DATAOverTolerance: The amount by which the piece may be larger than the Dimension shown.
  • DATAUnderTolerance: The amount by which the piece may be smaller than the Dimension shown.
  • DATAInverted: Marks whether the dimension represents a common or an inverted value.
False - the ordinary value is used. For length it is a positive number, for angle the oblique value (0° - 180°).
True - the inverted value is used. For length a negative number, for angle the reflex value (180° - 360°).

Format

  • DATAFormatSpec: Allows additional text to be added to the dimension text.
Dimension value will replace the %.2f part of text (or any other valid format specifier - see printf).
  • DATAArbitrary: Specifies, whether treat FormatSpec as a template or an actual text.
False - replace the format specifier with the actual dimensional value.
True - ignore the dimensional value and display exactly FormatSpec as value.

View

Base

  • VIEWVisibility: Sets whether the dimension is visible. True - visible, False - hidden.

Dim Format

  • VIEWFont: The name of the font to use for the dimension text.
  • VIEWFontSize: Dimension text size in mm.
  • VIEWLineWidth: Dimension line weight.
  • VIEWColor: Color for lines and text.
  • VIEWStandardAndStyle: Specifies the standard (and the style of it) according to which the dimension is drawn:
ISO Oriented - drawn according to ISO 129.1 (international standard), text is rotated to be parallel with the dimension line tangent.
ISO Referencing - drawn in compliance with ISO-129.1, text is always horizontal, above the shortest possible reference line.
ASME Inlined - drawn according to ASME Y14.5M (US standard), text is horizontal, inserted in a break within the dimension line or arc.
ASME Referencing - drawn in compliance with ASME Y14.5M, text is horizontal, short reference line is attached to one side's vertical center.
  • VIEWRenderingExtent: Rather universal property specifying how much space the dimension drawing may take up:
None - no lines or arrows are drawn, only the bare dimension value is displayed.
Minimal - for lengths and angles a single headed line connecting the dimensional value and the end point's virtual extension line is drawn. The extension line itself is not added.
Diameters are rendered following Confined extent, radii following Reduced extent.
Confined - for lengths and angles a double headed line (or arc) connecting the start and end point's virtual extension lines is drawn, though the extension lines themselves are not added.
Diameters are drawn with a minimal single headed line from dimensional value to the closest point on circle, radii as with Reduced extent.
Reduced - for lengths and angles a single headed line connecting the dimensional value and the end point's extension line is drawn along with the extension line itself.
Diameters are drawn with a single headed line from the center to the closest point on circle, radii with a minimal single headed line from dimensional value to the closest arc point.
Normal - the default value. For lengths and angles a double headed line (or arc) connecting the start and end point's extension lines is drawn, the extension lines themselves as well.
Diameters are drawn as double headed lines striking the center and connecting the closest and farthest points on the circle.
Radii are drawn as a single headed line from center to the closest arc point.
Expanded - Only diameters support this value, rendering them in a horizontal or vertical length-like way. Other dimension types are rendered as with Normal extent.
  • VIEWFlipArrowheads: By default the value inside the dimension line/arc means the arrows pointing outwards. If placed outside the dimension line/arc, the arrows point inwards the dimension line/arc.
False - Let the direction of arrows to be selected automatically according to the rule above.
True - Override the automatically chosen direction and force the opposite one.

Standard and Style

For a quick preview and presentation of the 4 basic Standard And Style differences, please see the picture below (from https://forum.freecadweb.org/viewtopic.php?f=35&t=39571):

TechDraw Dimension standardization.png

Scripting

See also: TechDraw API and FreeCAD Scripting Basics.

The Dimension Length tool can be used in macros and from the Python console by using the following functions:

dim1 = FreeCAD.ActiveDocument.addObject('TechDraw::DrawViewDimension','Dimension')
dim1.Type = "Distance"
dim1.References2D=[(view1, 'Edge1')]
rc = page.addView(dim1)


Notes

  • Edge selection. Edges can be difficult to select. You can adjust the selection area for edges using the parameter "/Mod/TechDraw/General/EdgeFuzz" (see Std_DlgParameter). This is a dimension-less number. The default is 10.0. Values in the 20-30 range will make it noticeably easier to select edges. Large numbers will cause overlaps with other drawing elements.
  • Decimal places. Dimensions use the global decimal places setting by default. This can be changed via preferences or by changing the FormatSpec property.