CRhinoTabbedDockBarDialog start position


I’m trying to adjust the positions of my two CRhinoTabbedDockBarDialog (TAB_0 and TAB_1 at image)
I need to do it in source code.

So the questions are:

  1. TAB_0: Is it possible somehow to find the DockBar with Rhinoceros tab (Layer, properties…) and integrate my TAB_0 in it.
  2. TAB_1: Is it possible to place the DockBar under another one (when both docked to the right). I think I found that it’s impossible for now. But still want to clarify (Position dockbars)

I appreciate any help you can provide

(John Morse) #3


I wrote this function as an example of how to display a custom panel in the same dock bar another panel:

static void OpenPanelInDockBarWithOtherPanel(CRhinoDoc& doc, const ON_UUID& panelToOpen, const ON_UUID& otherPanel, bool makeSelectedPanel)
  // Make sure the other panel is open first
  CRhinoTabbedDockBarDialog::OpenDockbarTab(doc, otherPanel, false);
  // Get the dock bar containing the other panel
  CRhinoUiDockBar* bar = CRhinoTabbedDockBarDialog::DockBarForTab(doc, otherPanel);
  // Open the panel in the same dock bar as the other panel
  CRhinoTabbedDockBarDialog::OpenTabOnDockBar(bar, doc, panelToOpen, makeSelectedPanel);

The following call will display a sample panel in the same container as the Rhino layers panel:

OpenPanelInDockBarWithOtherPanel(*doc, CSampleTabbedDockBarDialog::ID(), uuidPanelLayers, false);

This post provides the answer for question two and nothing has changed regarding that issue.


Thank you very much!
I didn’t have CRhinoTabbedDockBarDialog::OpenTabOnDockBar.
So after updating of Rhino 5 C++ SDK I can use it.:blush: