DGKC Control Documentation


Skip Navigation Links.
Start page
Quick Start
Search Page
Installation
What is new
Licensing
Collapse ModelsModels
Collapse DG Kernel ControlDG Kernel Control
Collapse API ReferenceAPI Reference
Interface List
Vector Space
Collapse General GeometryGeneral Geometry
Collapse ModelModel
Collapse ViewView
Collapse General ComputingGeneral Computing
Collapse ViewsViews
Collapse Samples and TutorialsSamples and Tutorials
Collapse GraphicsGraphics
Collapse Math ObjectsMath Objects
Collapse DeprecatedDeprecated
Redistribution
Model Viewer
Support
Skip Navigation Links Go to ActiveX docs Search Documentation


Two Dimensional Editor

At the time of writing this topic Two Dimensinal editor means only Overlay Editor, which may change in future releases.

2D Editors interact with end user to allow direct modification of a 2D Model

Access to a 2D editor is implemented via I2DEditor_DG. See Overlay topic about obtaining this interface.

Use I2DEditor_DG.EditableObject property to obtain IEntity_DG of the overlay. Query IModel_DG from IEntity_DG of the overlay to access its 2D geometry. Use methods of IModel_DG to modify structure of the 2D model and parametrs of its items and elements. More details.

Event Notifcations

To notify the application about different actions by the end user, 2D editors raise DgkMisc events with the DgkMiscEventArgs.eventType parameter set to Event_DG.TwoDimEditor. The DgkMiscEventArgs.param0 member is an integer with value one of EditorEvent_DG:

ID Event Raised
Activated The editor has been activated Always
ModelStructureChanged A new item aded to the 2D model or deleted If context boolean parameter 0 is true. See below
ItemStructureChanged Number of elements in an item has chanded. New element added or deleted If context boolean parameter 1 is true. See below
Closing The editor is about to be closed Always

For performance frequent events ModelStructureChanged and EventItemStructureChanged are not raised by default. They have to be requested with:

Use I2DEditor_DG.GetContext() or query IContext_DGt from I2DEditor_DG. Call IContext_DG.SetBool(0, true) to request ModelStructureChanged. Call IContext_DG.SetBool(1, true) to request ItemStructureChanged.