Draft Line/ru

Draft Line

Расположение в меню
Черчение → Линия
Верстаки
Draft, Arch
Быстрые клавиши
L I
Представлено в версии
-
См. также
Draft Wire

Описание

Инструмент «Линия» создает прямую линию, определяемую двумя точками. Он использует набор Draft Linestyle на панели инструментов «Тревожный лоток». Инструмент «Линия» ведет себя точно так же, как инструмент Draft Wire, за исключением того, что он останавливается после двух точек.

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

Применение

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

  1. There are several ways to invoke the command:
    • Press the Line button.
    • Draft: Select the Drafting → Line option from the menu.
    • BIM: Select the 2D Drafting → Line option from the menu.
    • Use the keyboard shortcut: L then I.
  2. The Line task panel opens. See Options for more information.
  3. Pick the first point in the 3D view, or type coordinates and press the Enter point button.
  4. Pick the second point in the 3D view, or type coordinates and press the Enter point button.

Опции

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 1.0).

Примечания

Настройки

See also: Preferences Editor and Draft Preferences.

Свойства

См. Draft Wire.

Программирование

See also: Autogenerated API documentation and FreeCAD Scripting Basics.

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)

Пример:

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()