TechDraw "Вставить группу проекций"

From FreeCAD Documentation
This page is a translated version of the page TechDraw ProjectionGroup and the translation is 25% complete.
Outdated translations are marked like this.
Other languages:

Вставить группу проекций

Системное название
TechDraw_ProjectionGroup
Расположение в меню
TechDraw → Вставить группу проекций
Верстаки
TechDraw
Быстрые клавиши
Нет
Представлено в версии
-
См. также
Вставить Вид, Вставить Вид сечения

Описание

The TechDraw ProjectionGroup tool creates a multiview projection of one or more 3D objects. The isometric views of the 4 front corners can also be included.

If you only want to produce a single view, there is no advantage in using ProjectionGroup; you should then use Insert View instead. If you do not wish to use the traditional first- / third-angle projection, you should use multiple Views (Insert View) instead of ProjectionGroup.

Three orthogonal views and one isometric view of a solid object

Применение

  1. Optionally rotate the 3D view. The camera direction in the 3D view determines the initial value of the Primary Direction of the Projection Group (the ДанныеDirection property of the central view).
  2. Select one or more objects in the 3D view or Tree view.
  3. If there are multiple drawing pages in the document: optionally add the desired page to the selection by selecting it in the Tree view.
  4. There are several ways to invoke the tool:
    • Press the Insert Projection Group button.
    • Select the TechDraw → TechDraw Views → Insert Projection Group option from the menu.
  5. If there are multiple drawing pages in the document and you have not yet selected a page, the Page Chooser dialog box opens: introduced in version 0.20
    1. Select the desired page.
    2. Press the OK button.
  6. The Projection Group task panel opens.
  7. Select which views should appear in the Projection Group, and the Projection Group's scale and other parameters.
  8. Press the OK button.
  9. Optionally move the Projection Group by dragging its central view.
  10. Optionally move the Projection Group's other views relative to the central view by dragging them individually.

Projection Group task panel. The Primary Direction field indicates the current view direction.

Свойства

Data

Base

  • ДанныеSource (LinkList): Links to the drawable objects to be depicted.
  • ДанныеXSource (XLinkList): Links to the drawable objects in an external file.
  • ДанныеAnchor (Link): The central view in the group. Normally the Front view.
  • ДанныеProjectionType (Enumeration): First Angle or Third Angle.

For the other properties in this group see TechDraw View.

Collection

  • ДанныеViews (LinkList): Links to the views in this ProjectionGroup.

Distribute

  • ДанныеAuto Distribute (Bool): If true, space out individual views automatically. Use false to position manually.
  • Данныеspacing X (Length): Horizontal space between views when automatically positioned. Note that Scale and the size of other views in the group also influence the spacing.
  • Данныеspacing Y (Length): Vertical space between views when automatically positioned.

View

Base

See TechDraw View.

Notes

The ProjectionGroup as a whole inherits X, Y, ScaleType, Scale and Rotation from the basic View.

Individual Views within the group inherit all part view properties, but the ProjectionGroup object controls the scale of all its member Views.

The RotationVector property of individual Views within the group is deprecated as of v0.19. Use XDirection instead.

Note that the central box displays the current projection direction of the primary view. It cannot be used to change the direction.

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

См. так же: TechDraw API и Основы составления скриптов FreeCAD.

A Projection Group can be created with macros and from the Python console by using the following functions:

import FreeCAD as App

doc = App.ActiveDocument
cyl = doc.addObject("Part::Cylinder", "Cylinder")
doc.recompute()

page = doc.addObject("TechDraw::DrawPage", "Page")
template = doc.addObject("TechDraw::DrawSVGTemplate", "Template")
template.Template = App.getResourceDir() + "Mod/TechDraw/Templates/A4_LandscapeTD.svg"
page.Template = template

# Toggle the visibility of the page to ensure its width and height are updated (hack):
page.Visibility = False
page.Visibility = True

group = doc.addObject("TechDraw::DrawProjGroup", "ProjGroup")
page.addView(group)
group.Source = [cyl]
group.ProjectionType = "Third Angle"

front_view = group.addProjection("Front") # First projection will become the Anchor.
group.Anchor.Direction = (0, 1, 0)
group.Anchor.RotationVector = (1, 0, 0)

left_view = group.addProjection("Left")
top_view = group.addProjection("Top")

group.X = page.PageWidth / 2
group.Y = page.PageHeight / 2

doc.recompute()

Note: The Projection Group should always be added to the Page, page.addView(group), before adding projections to the Group. This allows the Projection Group to use default parameter values derived from the parent page.