Replicating default toolbar buttons?

Let's say I want to have my custom toolbar outside eyeshot control and would like to hide eyeshot's one. What would be the proper way to replicate eyeshot's native toolbar?

i.e. for Zoom to Fit I'd call ActiveViewport.ZoomFit() method, but other toolbar buttons aren't that trivial, i.e. Magnifying Glass doesn't have an obvious "StartMagnifyingGlass()" method or similar. While ActiveViewport.ZoomWindow expects me to pass the actual window coordinates (doesn't let user draw expected window).

The other approach I'm considering is to "click" toolbar buttons in code to get the desired behavior, but ToolbarButton class doesn't have a "Execute" method or similar.

0

Comments

1 comment
Date Votes
  • FYI if anybody else has this question - setting Design.ActionMode property accordingly does the trick.

    1

Please sign in to leave a comment.

Didn't find what you were looking for?

New post