AnsweredAssumed Answered

API: Determine Item Rolled Over in Feature Manager to Implement Dynamic Highlighting

Question asked by Henry Lamousin on Jun 28, 2018

I found this previous question from 2013 unanswered:


"In my C# addin I have a tree of components. I'd like to implement the same dynamic highlighting with bounding boxes that the Feature Manager does in my component tree as the mouse moves over the component tree items. I have averything set up but I can't seem to find any APIs that do the same highlighting.


Does anyone have some tips or sample code on how to do this?"


I believe I have the same issue.


We have an add-in which creates macro features.  The add-in is responsible for rendering the feature.  I'd like to render the feature highlighted when its corresponding tree node is rolled over in the Feature Manager.  Unfortunately I've yet to find a way to determine what node the mouse is over, using the API.  IPartDoc exposes a DynamicHighlightNotify event.  This does fire when the mouse moves over a node in the Feature Manager.  Unfortunately I cannot determine what node the mouse is over.  The SelectionManager is no help as the object associated with the node is not considered selected.  Also, the IPartDoc.UserSelectionPreNotify event isn't fired for this case.


Does anyone know if this is possible, and if so how?