Site Tools


Show or Hide Rhino's Status Bar

Developer: C++
Summary: Demonstrates how to programmatically show or hide the Rhino status bar

When you run the Options command, all Rhino's options or application settings that you see are maintained by a CRhinoAppSettings class stored on the Rhino application object. This class is a container class as it holds several other CRhinoApp_xxx_Settings classes that help to organize all the options.

The process for modifying any Rhino option is:

  1. Find the container class in CRhinoAppSettings that holds the option you want to change.
  2. Make a copy of that container class.
  3. Change the appropriate members.
  4. Replace Rhino's copy of that container class with yours by calling one of CRhinoAppSettings' Set_xxx_Settings() member functions.

Example

The following sample source code demonstrates how to show or hide Rhino's status bar using the Rhino SDK.

void ShowRhinoStatusBar( BOOL bShow )
{
  // Copy the CRhinoAppAppearanceSettings class 
  CRhinoAppAppearanceSettings settings = RhinoApp().AppSettings().AppearanceSettings( true );
  if( settings.m_show_statusbar != bShow )
  {
    // Modify the desired setting
    settings.m_show_statusbar = bShow;
    // Replace the CRhinoAppAppearanceSettings with the modified version
    RhinoApp().AppSettings().SetAppearanceSettings( settings );
  }
}
developer/sdksamples/showrhinostatusbar.txt ยท Last modified: 2020/08/14 (external edit)