App Link/ru: Difference between revisions

From FreeCAD Documentation
(Created page with "==Свойства==")
(Created page with "=== Данные ===")
Line 22: Line 22:
These are the properties available in the [[property editor|property editor]] for an empty {{incode|App::Link}}.
These are the properties available in the [[property editor|property editor]] for an empty {{incode|App::Link}}.


=== Data ===
=== Данные ===


{{TitleProperty|Link}}
{{TitleProperty|Link}}

Revision as of 09:30, 14 May 2020

Введение

App Link, или, формально, App::Link, это элемент, который возвращает ссылку на другой объект в документе или внешнем документе. Объект появился introduced in version 0.19, с целью повторного использования уже созданных объектов, что очень полезно для создания сборок.

При создании обычной копии созданного объекта (например, через Part SimpleCopy‎), дублицируется весь новый объект с его топологической формой, что потребляет много памяти. App Link используется для повторного использования существующих данных существующих объектов, так что не надо создавать все новые объекты. Это улучшает поддержку копий, в частности в контексте механических сборок, где может быть нужно много дубликатов, или где требуется импорт малых сборок внутрь больших.

Использование

  • App Links может быть создан нажатием LinkMake.

Примечание: App Link это внутренний объект, так что он в основном предназначен для использования разработчиками для создания верстаков сборки. Например, этот объект используют верстаки Assembly3 и Assembly4.

Свойства

See Property for all property types that scripted objects can have.

An App::Link object is not derived from a Part Feature, however, if the Link has a reference to an external object, it will show the properties of the latter object.

These are the properties available in the property editor for an empty App::Link.

Данные

Link

  • ДанныеLinked Object:
  • ДанныеLink Transform:
  • ДанныеPlacement:
  • ДанныеShow Element:
  • ДанныеElement Count:
  • ДанныеScale:

Base

  • ДанныеLabel:

View

Link

  • ВидDraw Style:
  • ВидLine Width:
  • ВидOverride Material:
  • ВидPoint Size:
  • ВидSelectable:
  • ВидShape Material:

Base

  • ВидOn Top When Selected:
  • ВидSelection Style:
  • ВидShow In Tree:
  • ВидVisibility:

Inheritance

Simplified diagram of the relationships between the core objects in the program. The App::Link object is a core component of the system, it does not depend on any workbench, but it can be used with most objects created in all workbenches.

Scripting

Смотри так же: FreeCAD Scripting Basics, и scripted objects.

Смотрите Part Feature для общей информации.

An App Link is created with the addObject() method of the document.

import FreeCAD as App

doc = App.newDocument()
obj = App.ActiveDocument.addObject("App::Link", "Name")
obj.Label = "Custom label"

Further reading

The App Link object was introduced after 2 years of development and prototyping. This component was thought and developed almost single-handedly by user realthunder. The motivations and design implementations behind this project are described in his GitHub page, Link. In order to accomplish this feature, several core changes to FreeCAD were made; these were also extensively documented in Core-Changes.

The App Link project started after the redesign of the PartDesign Workbench was complete in v0.17. The history of App Link can be traced to some essential forum threads:

Finally, the pull request and merge happened: