Rhino.UI.Panels.OpenPanel on mac

Hey guys,

I am trying to use Rhino.UI.Panels.OpenPanel on mac, and finding some apparently problematic behavior. To reproduce it, you can:

  1. In OnLoad, call RegisterPanel using Dale’s SampleCsEtoPanel.
  2. In a command, call OpenPanel with SampleCsEtoPanel.PanelId.
  3. Build and run.
  4. Run your command; the panel pops up.

At this point, everything is working as expected; the panel stays above the Rhino window even when it loses focus, and you can close it and run the command again, and it will re-open and continue to work the same.

However, once you click the “Hello” button, the behavior will change; now, the panel will disappear below the Rhino window if it loses focus, and you will need to use CTRL+DOWN to find it. Closing the panel and running your command again to re-open it, it will briefly flash above the Rhino window before disappearing below again. This will continue until you restart the application, at which point the pattern will repeat.

Please let me know whether you can reproduce this, and/or whether it is supposed to be working this way. I am using here the current WIP 5.3 (5D92w) and the current release 5.2.3 (5C258) on el capitan.


@JohnM, do you know anything about this?

Hello Jeremy,

The sample code has a small problem with the way it calls the message box, it is using the Eto version of the message box which expects a top level Eto Window which is what is getting the view controller messed up under the hood. Fortunately there is a simple work around, use the Rhino.UI.Dialogs.ShowMessage method instead and everything works fine. I tested this in Rhino 5 and 6 on both Mac and Windows and it works as expected.

Please let me know if you have any other problems with the Panel code.

Great, thanks John.