Draft Line/cs: Difference between revisions

From FreeCAD Documentation
(Updating to match new version of source page)
(Updating to match new version of source page)
 
(15 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<languages/>
<languages/>

{{Docnav||[[Draft_Wire|Wire]]|[[Draft_Module|Draft]]|IconC=Workbench_Draft.svg|IconR=Draft_Wire.svg}}
{{Docnav
|
|[[Draft_Wire|Wire]]
|[[Draft_Workbench|Draft]]
|IconL=
|IconR=Draft_Wire.svg
|IconC=Workbench_Draft.svg
}}


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
{{GuiCommand/cs|Name=Draft Line|Name/cs=Kreslení Přímka|Workbenches=[[Draft Module/cs|Kreslení]], [[Arch Module/cs|Architektura]]|MenuLocation=Kreslení → Přímka|Shortcut=L I|SeeAlso=[[Draft Wire/cs|Kreslení drát]]}}
{{GuiCommand/cs|Name=Draft Line|Name/cs=Kreslení Přímka|Workbenches=[[Draft_Workbench/cs|Kreslení]], [[Arch_Workbench/cs|Architektura]]|MenuLocation=Kreslení → Přímka|Shortcut=L I|SeeAlso=[[Draft Wire/cs|Kreslení drát]]}}
</div>
</div>

==Description==


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
Line 10: Line 20:
Nástroj Přímka vytváří rovnou dvoubodovou přímku v aktuální [[Draft SelectPlane/cs|pracovní rovině]]. Použije se [[Draft Linestyle/cs|tloušťka čáry a barva]] předem zadaná v záložce Nástrojů. Nástroj Přímka se chová přesně stejně jako nástroj [[Draft Wire/cs|Drát (lomená čára)]] kromě toho že končí po zadání dvou bodů.
Nástroj Přímka vytváří rovnou dvoubodovou přímku v aktuální [[Draft SelectPlane/cs|pracovní rovině]]. Použije se [[Draft Linestyle/cs|tloušťka čáry a barva]] předem zadaná v záložce Nástrojů. Nástroj Přímka se chová přesně stejně jako nástroj [[Draft Wire/cs|Drát (lomená čára)]] kromě toho že končí po zadání dvou bodů.
</div>
</div>

A Draft Line is in fact a [[Draft_Wire|Draft Wire]] with only two points.


[[Image:Draft_Line_example.jpg|400px]]
[[Image:Draft_Line_example.jpg|400px]]
Line 15: Line 27:
[[Image:Draft_Line_example.jpg|400px]]
[[Image:Draft_Line_example.jpg|400px]]
</div>
</div>

==Usage==

See also: [[Draft_Tray|Draft Tray]], [[Draft_Snap|Draft Snap]] and [[Draft_Constrain|Draft Constrain]].


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
==Použití==
==Použití==
# Stiskněte tlačítko {{KEY|[[Image:Draft Line.png|16px]] [[Draft Line|Přímka]]}} nebo klávesy {{KEY|L}} pak {{KEY|I}}
# Stiskněte tlačítko {{KEY|[[Image:Draft Line.png|16px]] [[Draft Line|Přímka]]}} nebo klávesy {{KEY|L}} pak {{KEY|I}}
# Klikněte na první bod ve 3D pohledu nebo zadejte [[Draft_Coordinates|souřadnice]]
# Klikněte na první bod ve 3D pohledu nebo zadejte souřadnice
# Klikněte na druhý bod ve 3D pohledu nebo zadejte [[Draft_Coordinates|souřadnice]].
# Klikněte na druhý bod ve 3D pohledu nebo zadejte souřadnice.
</div>
</div>


==Options==
The line can be edited by double clicking on the element in the tree view, or by pressing the {{Button|[[Image:Draft Edit.svg|16px]] [[Draft Edit|Draft Edit]]}} button. Then you can move the points to a new position.


The single character keyboard shortcuts available in the task panel can be changed. See [[Draft_Preferences|Draft Preferences]]. The shortcuts mentioned here are the default shortcuts (for version 0.22).
===Fusing single lines===
If several connected [[Draft Line|Draft Lines]] are selected they can be fused into a wire by pressing the {{Button|[[Image:Draft Upgrade.svg|16px]] [[Draft Upgrade|Draft Upgrade]]}} tool; however, this wire will not be editable. To create an editable wire, use {{Button|[[Image:Draft Upgrade.svg|16px]] [[Draft Upgrade]]}} three more times on the new shapes (wire, closed wire, face). You can also fuse the original lines with the {{Button|[[Image:Draft Wire.svg|16px]] [[Draft Wire|Draft Wire]]}} tool.

A wire can also be created from a single line by adding another point anywhere along its length. To do this, press the {{Button|[[Image:Draft_AddPoint.svg|16px]] [[Draft_AddPoint|add point]]}} button, and click anywhere on the line.


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
Line 38: Line 51:
* Stiskněte při kreslení klávesu {{KEY|CTRL}} pro [[Draft_Snap|přichycení]] Vašeho bodu k nejbližšímu uchopovacímu místu, nezávisle na vzdálenosti od něho.
* Stiskněte při kreslení klávesu {{KEY|CTRL}} pro [[Draft_Snap|přichycení]] Vašeho bodu k nejbližšímu uchopovacímu místu, nezávisle na vzdálenosti od něho.
* Stiskněte při kreslení klávesu {{KEY|SHIFT}} pro nastavení [[Draft_Constrain|vazby]] Vašeho dalšího bodu vodorovně nebo svisle v relaci k předchozímu bodu.
* Stiskněte při kreslení klávesu {{KEY|SHIFT}} pro nastavení [[Draft_Constrain|vazby]] Vašeho dalšího bodu vodorovně nebo svisle v relaci k předchozímu bodu.
* Stiskněte klávesy {{KEY|CTRL}}+{{KEY|Z}} nebo tlačítko {{KEY|[[Image:Draft UndoLine.png|12px]] '''[[Draft_UndoLine|Undo]]'''}} ke zrušení posledního bodu.
* Stiskněte klávesy {{KEY|CTRL}}+{{KEY|Z}} nebo tlačítko {{KEY|[[Image:Draft UndoLine.png|12px]] '''Undo'''}} ke zrušení posledního bodu.
* Stiskněte klávesu {{KEY|ESC}} nebo tlačítko {{KEY|'''Cancel'''}} pro ukončení aktuálního příkazu Přímka.
* Stiskněte klávesu {{KEY|ESC}} nebo tlačítko {{KEY|'''Cancel'''}} pro ukončení aktuálního příkazu Přímka.
</div>
</div>

==Notes==

* A Draft Line can be edited with the [[Draft_Edit|Draft Edit]] command.
* Draft Lines and [[Draft_Wire|Draft Wires]] can be joined with the [[Draft_Wire|Draft Wire]] command, the [[Draft_Join|Draft Join]] command or the [[Draft_Upgrade|Draft Upgrade]] command.

==Preferences==

See also: [[Preferences_Editor|Preferences Editor]] and [[Draft_Preferences|Draft Preferences]].

* To change the initial focus of the task panel to the {{MenuCommand|Length}} input box: {{MenuCommand|Edit → Preferences... → Draft → General → Set focus on Length instead of X coordinate}}. Note that you must move the pointer in the [[3D_view|3D view]] for the change to take effect.
* If the {{MenuCommand|Edit → Preferences... → Draft → General → Create Part primitives if possible}} option is checked, the command will create a [[Part_Line|Part Line]] instead of a Draft Line.

==Properties==


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
Line 49: Line 76:
</div>
</div>


===Data===
==Scripting==
* {{PropertyData|Start}}: specifies the start point.
* {{PropertyData|End}}: specifies the end point.
* {{PropertyData|Subdivisions}}: specifies the number of interior nodes in the line. {{version|0.16}}
* {{PropertyData|Length}}: (read-only) specifies the length of the segment.

===View===
* {{PropertyView|End Arrow}}: if it is {{TRUE}} it will display a symbol at the last point of the line, so it can be used as an annotation line.
* {{PropertyView|Arrow Size}}: specifies the size of the symbol displayed at the end of the line.
* {{PropertyView|Arrow Type}}: specifies the type of symbol displayed at the end of the line, which can be "Dot", "Circle", "Arrow", or "Tick".


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
Line 65: Line 83:
</div>
</div>


To create a Draft Line use the {{incode|make_line}} method ({{Version|0.19}}) of the Draft module. This method replaces the deprecated {{incode|makeLine}} method.
The Line tool can be used in [[macros|macros]] and from the [[Python|Python]] console by using the following function:

{{Code|code=
{{Code|code=
Line = makeLine(p1, p2)
line = make_line(p1, p2)
Line = makeLine(LineSegment)
line = make_line(LineSegment)
Line = makeLine(Shape)
line = make_line(Shape)
}}
}}


Line 78: Line 97:


Příklad:
Příklad:

{{Code|code=
{{Code|code=
import FreeCAD, Draft
import FreeCAD as App
import Draft


doc = App.newDocument()
p1 = FreeCAD.Vector(0, 0, 0)
p2 = FreeCAD.Vector(1000, 500, 0)
p3 = FreeCAD.Vector(-250, -500, 0)
p4 = FreeCAD.Vector(500, 1000, 0)


Line1 = Draft.makeLine(p1, p2)
p1 = App.Vector(0, 0, 0)
Line2 = Draft.makeLine(p3, p4)
p2 = App.Vector(1000, 500, 0)
p3 = App.Vector(-250, -500, 0)
p4 = App.Vector(500, 1000, 0)

line1 = Draft.make_line(p1, p2)
line2 = Draft.make_line(p3, p4)

doc.recompute()
}}
}}


{{Docnav||[[Draft_Wire|Wire]]|[[Draft_Module|Draft]]|IconC=Workbench_Draft.svg|IconR=Draft_Wire.svg}}


{{Docnav
{{Draft Tools navi}}
|
|[[Draft_Wire|Wire]]
|[[Draft_Workbench|Draft]]
|IconL=
|IconR=Draft_Wire.svg
|IconC=Workbench_Draft.svg
}}


{{Draft Tools navi{{#translation:}}}}
{{Userdocnavi}}
{{Userdocnavi{{#translation:}}}}
{{clear}}

Latest revision as of 05:00, 9 January 2024

Kreslení Přímka

Umístění Menu
Kreslení → Přímka
Pracovní stoly
Kreslení, Architektura
Výchozí zástupce
L I
Představen ve verzi
-
Viz také
Kreslení drát

Description

Popis

Nástroj Přímka vytváří rovnou dvoubodovou přímku v aktuální pracovní rovině. Použije se tloušťka čáry a barva předem zadaná v záložce Nástrojů. Nástroj Přímka se chová přesně stejně jako nástroj Drát (lomená čára) kromě toho že končí po zadání dvou bodů.

A Draft Line is in fact a Draft Wire with only two points.

Usage

See also: Draft Tray, Draft Snap and Draft Constrain.

Použití

  1. Stiskněte tlačítko Přímka nebo klávesy L pak I
  2. Klikněte na první bod ve 3D pohledu nebo zadejte souřadnice
  3. Klikněte na druhý bod ve 3D pohledu nebo zadejte souřadnice.

Options

The single character keyboard shortcuts available in the task panel can be changed. See Draft Preferences. The shortcuts mentioned here are the default shortcuts (for version 0.22).

Volby

  • Po zadání prvního bodu stiskněte X, Y nebo Z pro určení osy druhého bodu.
  • Pro zadání souřadnic ručně, jednoduše zadejte číslo a stiskněte ENTER mezi každou z komponent X, Y a Z.
  • Stiskněte klávesu R nebo klikněte/odklikněte zaklikávací políčko Relativní. Je-li nastaven relativní mód jsou souřadnice následujícího bodu relativní k předchozímu bodu. Je-li mód absolutní souřadnice jsou vztaženy k počátečnímu bodu (0,0,0).
  • Stiskněte klávesu T nebo klikněte/odklikněte zaklikávací políčko Pokračovat. Je-li nastaven pokračovací mód, nástroj Přímka bude po ukončení křivky restartován a připraven ke kreslení další přímky bez nutnosti znovu jej spouštět klikáním na tlačítko Přímka.
  • Stiskněte při kreslení klávesu CTRL pro přichycení Vašeho bodu k nejbližšímu uchopovacímu místu, nezávisle na vzdálenosti od něho.
  • Stiskněte při kreslení klávesu SHIFT pro nastavení vazby Vašeho dalšího bodu vodorovně nebo svisle v relaci k předchozímu bodu.
  • Stiskněte klávesy CTRL+Z nebo tlačítko Undo ke zrušení posledního bodu.
  • Stiskněte klávesu ESC nebo tlačítko Cancel pro ukončení aktuálního příkazu Přímka.

Notes

Preferences

See also: Preferences Editor and Draft Preferences.

  • To change the initial focus of the task panel to the Length input box: Edit → Preferences... → Draft → General → Set focus on Length instead of X coordinate. Note that you must move the pointer in the 3D view for the change to take effect.
  • If the Edit → Preferences... → Draft → General → Create Part primitives if possible option is checked, the command will create a Part Line instead of a Draft Line.

Properties

Vlastnosti

  • DATAPočátek: Počáteční bod
  • DATAKonec: Koncový bod
  • DATASubdivisions: Divides the line with the given number of subdivisions introduced in version 0.16

Scripting

Skriptování

Nástroj Přímka může být využit v makrech a z konzoly Pythonu použitím následující funkce:

To create a Draft Line use the make_line method (introduced in version 0.19) of the Draft module. This method replaces the deprecated makeLine method.

line = make_line(p1, p2)
line = make_line(LineSegment)
line = make_line(Shape)
  • Vytvoří přímku mezi dvěma zadanými vektory. Pro kreslení je použita aktuálně nastavená šířka a barva čáry.
  • Vrací nově vytvořený objekt.

Příklad:

import FreeCAD as App
import Draft

doc = App.newDocument()

p1 = App.Vector(0, 0, 0)
p2 = App.Vector(1000, 500, 0)
p3 = App.Vector(-250, -500, 0)
p4 = App.Vector(500, 1000, 0)

line1 = Draft.make_line(p1, p2)
line2 = Draft.make_line(p3, p4)

doc.recompute()