TechDraw 2LineCenterLine: Difference between revisions

From FreeCAD Documentation
No edit summary
No edit summary
(27 intermediate revisions by 6 users not shown)
Line 3: Line 3:


<!--T:1-->
<!--T:1-->
{{Docnav
{{Docnav|[[TechDraw_FaceCenterLine|FaceCenterLine]]|[[TechDraw_2PointCenterLine|2PointCenterLine]]|[[TechDraw_Module|TechDraw]]|IconL=techdraw-facecenterline.svg|IconC=Workbench_TechDraw.svg|IconR=Techdraw-2pointcenterline.svg}}
|[[TechDraw_FaceCenterLine|Add Centerline to Face(s)]]
|[[TechDraw_2PointCenterLine|Add Centerline between 2 Points]]
|[[TechDraw_Module|TechDraw]]
|IconL=TechDraw_FaceCenterLine.svg
|IconC=Workbench_TechDraw.svg
|IconR=TechDraw_2PointCenterLine.svg
}}


<!--T:2-->
<!--T:2-->
{{GuiCommand
{{GuiCommand
|Name=TechDraw 2LineCenterLine
|Name=TechDraw 2LineCenterLine
|MenuLocation=TechDraw → Add Lines → Add Centerline between 2 Lines
|Icon=techdraw-2linecenterline.svg
|MenuLocation=TechDraw → 2LineCenterLine
|Workbenches=[[TechDraw Module|TechDraw]]
|Workbenches=[[TechDraw Module|TechDraw]]
|SeeAlso=[[TechDraw_FaceCenterLine|Add Centerline to Face(s)]], [[TechDraw_2PointCenterLine|Add Centerline between 2 Points]]
|SeeAlso=[[TechDraw FaceCenterLine]], [[TechDraw 2PointCenterLine]]
|Version=0.19
|Version=0.19
}}
}}
Line 18: Line 24:


<!--T:4-->
<!--T:4-->
The 2LineCenterLine tool adds a center line between two Edges.
The 2LineCenterLine tool adds a centerline between two Edges.


</translate>
</translate>
[[Image:CL2LinesSample.png]]
[[Image:CL2LinesSample.png|350px]]
<translate>
<translate>


<!--T:5-->
<!--T:5-->
{{Caption|Aligned center line between 2 Edges}}
{{Caption|Aligned centerline between 2 Edges}}


==How to use== <!--T:6-->
==Usage== <!--T:6-->


<!--T:7-->
<!--T:7-->
# Select 2 Edges in a View. The Edges should be more or less parallel.
# Select 2 Edges in a View. The Edges should be more or less parallel.
# Press the {{Button|[[Image:techdraw-2linecenterline.svg|16px]] [[TechDraw 2LineCenterLine|2LineCenterLine]]}} button
# Press the {{Button|[[Image:TechDraw_2LineCenterLine.svg|16px]] Add Centerline between 2 Lines}} button
# A dialog will open where you can specify attributes of the new center line.
# A dialog will open where you can specify attributes of the new centerline.
# A center line will be added between the 2 selected Edges.
# A centerline will be added between the 2 selected Edges.</br>If the generated line looks odd, you may need to use the option [[#Flip_Ends|'''Flip Ends''']].


<!--T:8-->
<!--T:25-->
To delete a Centerline, select it and use the toolbar button {{Button|[[Image:TechDraw_CosmeticEraser.svg|16px]] [[TechDraw_CosmeticEraser|Remove Cosmetic Object]]}}.
Note: If the generated center line looks particularly odd, you may need to edit the center line and click the "Flip ends" radio button.


==Editing Center Lines== <!--T:9-->
==Editing Centerlines== <!--T:9-->


<!--T:21-->
Any of the center line command buttons ({{Button|[[Image:techdraw-facecenterline.svg|16px]] [[TechDraw FaceCenterLine|FaceCenterLine]]}}, {{Button|[[Image:techdraw-2linecenterline.svg|16px]] [[TechDraw 2LineCenterLine|2LineCenterLine]]}},
Any of the centerline command buttons (
{{Button|[[Image:techdraw-2pointcenterline.svg|16px]] [[TechDraw 2PointCenterLine|2PointCenterLine]]}})
{{Button|[[Image:TechDraw_FaceCenterLine.svg|16px]] [[TechDraw_FaceCenterLine|Add Centerline to Face(s)]]}},
can be used to edit any center line.
{{Button|[[Image:TechDraw_2LineCenterLine.svg|16px]] Add Centerline between 2 Lines}},
{{Button|[[Image:TechDraw_2PointCenterLine.svg|16px]] [[TechDraw_2PointCenterLine|Add Centerline between 2 Points]]}})
can be used to edit any centerline.


<!--T:10-->
<!--T:10-->
# Select a center line.
# Select a centerline.
# Press any center line command button.
# Press any centerline command button.
# A dialog will open where you can change attributes of the center line.
# A dialog will open where you can change attributes of the centerline.
# Press OK to see your changes.
# Press {{Button|OK}} to see your changes.


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


<!--T:12-->
<!--T:12-->
Cosmetic center lines have no properties of their own, as they are not Document Objects. They do have attributes that can be changed in the center line edit dialog. Not all attributes apply to all center lines
Centerlines have no properties of their own, as they are no document objects. They have attributes that can be edited.

# Mode (radio buttons):
<!--T:22-->
## Vertical: force center line vertical
# Modus (radio buttons):
## Horizontal: force center line horizontal
#* '''Vertical''': Forces a centerline vertical
## Aligned: follow the general direction of the Edge for 2 Edge center line
#* '''Horizontal''': Forces a centerline horizontal
# Shift Horiz: move the center line left or right of its normal position
#* '''Aligned''': Follows the general direction of the Edge for 2 Edge centerline
# Shift Vert: move the center line up or down from its normal position
# '''Shift Horiz''': Moves the centerline left or right of its normal position
# Rotate: rotate the center line around its center (degrees. + CCW, -CW)
# '''Shift Vert''': Moves the centerline up or down from its normal position
# Extend: make the center line longer by this amount
# '''Rotate''': Rotates the centerline around its center (degrees. + counterclockwise, - clockwise)
# Color: color of center line
# '''Extend''': Makes the centerline longer by this amount
# Weight: thickness of the center line
# '''Color''': Color of centerline
# Style: NoLine, Solid, Dash, Dot, DashDot, DashDotDot
# '''Weight''': Thickness of the centerline
# Flip ends: sometimes required to make 2 line center lines behave correctly
# '''Style''': [[Image:Continuous-line.svg|20px]] Continuous, [[Image:Dash-line.svg|20px]] Dash, [[Image:Dot-line.svg|20px]] Dot, [[Image:DashDot-line.svg|20px]] DashDot, [[Image:DashDotDot-line.svg|20px]] DashDotDot
# '''Flip Ends''': Flips endpoints for creation as described below

==Flip Ends== <!--T:23-->

<!--T:24-->
[[Image:TD-CenterLineFlip.png|thumb|350px|Sketch how the centerline is constructed]]
The centerline between 2 lines is drawn between the midpoints (m0 and m1) of the lines that connects the endpoints of the selected lines (p0 and p1), see the sketch. Depending on the point order there are 2 possibilities to draw the connecting lines. The option '''Flip Ends''' flips the way the connecting lines are drawn.


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


<!--T:14-->
<!--T:14-->
{{Emphasis|See also:}} [[TechDraw API]] and [[FreeCAD Scripting Basics]].
{{Emphasis|See also:}} [[TechDraw API|TechDraw API]] and [[FreeCAD Scripting Basics|FreeCAD Scripting Basics]].


<!--T:15-->
<!--T:15-->
Cosmetic center lines are not accessible from [[macros]] or the [[Python]] console at this time.
Centerlines are not accessible from [[macros|macros]] or the [[Python|Python]] console at this time.

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

<!--T:17-->
# none


<!--T:18-->
<!--T:18-->
{{Docnav
{{Docnav|[[TechDraw_FaceCenterLine|FaceCenterLine]]|[[TechDraw_2PointCenterLine|2PointCenterLine]]|[[TechDraw_Module|TechDraw]]|IconL=techdraw-facecenterline.svg|IconC=Workbench_TechDraw.svg|IconR=Techdraw-2pointcenterline.svg}}
|[[TechDraw_FaceCenterLine|Add Centerline to Face(s)]]

|[[TechDraw_2PointCenterLine|Add Centerline between 2 Points]]
<!--T:19-->
|[[TechDraw_Module|TechDraw]]
{{TechDraw Tools navi}}
|IconL=TechDraw_FaceCenterLine.svg
|IconC=Workbench_TechDraw.svg
|IconR=TechDraw_2PointCenterLine.svg
}}


<!--T:20-->
{{Userdocnavi}}
</translate>
</translate>
{{TechDraw Tools navi{{#translation:}}}}
{{Userdocnavi{{#translation:}}}}
{{clear}}
{{clear}}

Revision as of 13:44, 13 April 2020

TechDraw 2LineCenterLine

Menu location
TechDraw → Add Lines → Add Centerline between 2 Lines
Workbenches
TechDraw
Default shortcut
None
Introduced in version
0.19
See also
Add Centerline to Face(s), Add Centerline between 2 Points

Description

The 2LineCenterLine tool adds a centerline between two Edges.

Aligned centerline between 2 Edges

Usage

  1. Select 2 Edges in a View. The Edges should be more or less parallel.
  2. Press the Add Centerline between 2 Lines button
  3. A dialog will open where you can specify attributes of the new centerline.
  4. A centerline will be added between the 2 selected Edges.
    If the generated line looks odd, you may need to use the option Flip Ends.

To delete a Centerline, select it and use the toolbar button Remove Cosmetic Object.

Editing Centerlines

Any of the centerline command buttons ( Add Centerline to Face(s), Add Centerline between 2 Lines, Add Centerline between 2 Points) can be used to edit any centerline.

  1. Select a centerline.
  2. Press any centerline command button.
  3. A dialog will open where you can change attributes of the centerline.
  4. Press OK to see your changes.

Properties

Centerlines have no properties of their own, as they are no document objects. They have attributes that can be edited.

  1. Modus (radio buttons):
    • Vertical: Forces a centerline vertical
    • Horizontal: Forces a centerline horizontal
    • Aligned: Follows the general direction of the Edge for 2 Edge centerline
  2. Shift Horiz: Moves the centerline left or right of its normal position
  3. Shift Vert: Moves the centerline up or down from its normal position
  4. Rotate: Rotates the centerline around its center (degrees. + counterclockwise, - clockwise)
  5. Extend: Makes the centerline longer by this amount
  6. Color: Color of centerline
  7. Weight: Thickness of the centerline
  8. Style: Continuous, Dash, Dot, DashDot, DashDotDot
  9. Flip Ends: Flips endpoints for creation as described below

Flip Ends

Sketch how the centerline is constructed

The centerline between 2 lines is drawn between the midpoints (m0 and m1) of the lines that connects the endpoints of the selected lines (p0 and p1), see the sketch. Depending on the point order there are 2 possibilities to draw the connecting lines. The option Flip Ends flips the way the connecting lines are drawn.

Scripting

See also: TechDraw API and FreeCAD Scripting Basics.

Centerlines are not accessible from macros or the Python console at this time.