DGKC Control Documentation


Skip Navigation Links.
Skip Navigation LinksHome Page > DG Kernel Control > Interactive Functionality > Auxiliary Views > Model Explorer Go to ActiveX docs Search Documentation


Model Explorer

Model Explorer of DG Kernel components is a useful tool, which displays structure of the model, allows quick finding of objects, manipulates view and performs some model editing operations like movement of objects, Boolean Subtract and other

To open model explorer select Advanced > Model Explorer in the context menu (right click)

The explorer handles multiple selection in the object tree. It follows the normal Windows multiple selection rules: Hold control to click several objects. Hold shift and click first and last to select a range of objects.

The "Position and Orientation" button displays and allows modification of location and orientation of an object or a set of them. The window shows/modifies the local frame of the object.

Model Explorer can be opened programmatically using IGlobalAPI_DG.LaunchExplorer()

Selection Notification

When requested, the component raises DgkMisc event to notify application about changes in item selection in the Model Explorer. Turn ExplorerSelectionNotify property of component context on to receive the notification.

In this case the eventType member of the MenuEventArgs callback parameter is the ExplorerSelection member of Event_DG Enumeration.

The actual type of the parameter param0 in MenuEventArgs is IList_DG. This is a list of entities currently selected in the Model Explorer. Elements of the list have type IEntity_DG.

Example:

 
void OnMiscEvent(object sender, DgkMiscEventArgs e)
{
    if (e.eventType == Event_DG.ExplorerSelection)
    {
        if (e.param0 != null)
        {
            IList_DG iList = (IList_DG)e.param0;
            foreach (IUnk unk in iList)
            {
                IEntity_DG entity = unk.Query();
                //...
            }
        }
    }
}

See also: eMotion sample.