IsToolbar

Verifies that a toolbar (or toolbar group) exists in a currently open toolbar collection.

Syntax

rhinoscriptsyntax.IsToolbar(name, toolbar, group=False)

Parameters

name

Required.  String.  The name of a currently open toolbar collection.

toolbar

Required.  String.  The name of a toolbar in the collection to verify.

group

Optional.  Boolean. True if the toolbar parameter is refering to a toolbar group

Returns

Boolean

True or false indicating success or failure.

Example

import rhinoscriptsyntax as rs

file = "C:\\SteveBaer\\AppData\\Roaming\\McNeel\\Rhinoceros\\5.0\\UI\\default.rui"

name = rs.IsToolbarCollection(file)

if name:

    if rs.IsToolbar(name, "Layer"):

        print "The collection contains the Layer toolbar."

    else:

        print "The collection does not contain the Layer toolbar."

Also See

HideToolbar

IsToolbarVisible

ShowToolbar

ToolbarCount

ToolbarNames