Layers are the primary organizational tool in Rhino. Layers are like transparent overlays on which you can organize and group objects.
With version 4.0, Rhino introduced hierarchical layers - layers that can have a parent layer and one or more child layers. This has made organizing projects easier.
With version 5.0, the hierarchical layer scheme has been extended to allow the same layer name to appear in different parts of the layer tree. This is conceptually similar to having the same file name in different location in the file system.
To prevent possible layer name conflicts, all RhinoScript functions now accept and return a layer's "full path" name. For example, if you have a root layer named "First Floor" and it has a child layer named "Electrical", you would refer to this layer as "First Floor::Electrical".
The following methods are available for adding, querying or manipulating layers.
Method |
Description |
Adds a new layer. |
|
Returns or changes the current layer. |
|
Removes an empty layer. |
|
Expands or contracts a layer. |
|
Returns user text that is stored on a layer. |
|
Verifies a layer exists. |
|
Verifies objects on a layer can be changed. |
|
Verifies a layer is a child of another layer. |
|
Verifies a layer is the current layer. |
|
Verifies a layer contains no objects. |
|
Verifies a layer is expanded. |
|
Verifies a layer is locked. |
|
Verifies a layer is on. |
|
Verifies a layer is a parent of another layer. |
|
Verifies a layer is reference. |
|
Verifies objects on a layer are selectable. |
|
Verifies objects on a layer are visible. |
|
Returns the number of child layers of a layer. |
|
Returns the names of a layer's child layers. |
|
Returns or changes a layer's color. |
|
Returns the number of layers. |
|
Returns the identifier of a layer given the layer's name. |
|
Returns the identifiers of all layers in the document. |
|
Returns or changes a layer's linetype. |
|
Returns or changes a layer's locked property. |
|
Returns or changes a layer's material index. |
|
Returns or changes a layer's mode. |
|
Returns the name of a layer given the layer's identifier. |
|
Returns layer names. |
|
Returns a layer's display order index. |
|
Returns or changes a layer's print color. |
|
Returns or changes a layer's print width. |
|
Returns or changes a layer's visibility property. |
|
Matches layer properties. |
|
Merges a layer with another layer. |
|
Returns a layer's parent layer. |
|
Removes an existing layer. |
|
Renames a layer. |
|
Returns the layers that are selected in Rhino's layer UI. |
|
Selects layers in Rhino's layer UI. |
|
Sets or removes user text stored on a layer. |