Rhino C++ API
8.14
|
#include <rhinoSdkLayer.h>
Public Types | |
enum | LayerProperty : unsigned int { LayerProperty::None = 0x0, LayerProperty::Current = 0x1, LayerProperty::Visible = 0x2, LayerProperty::Locked = 0x4, LayerProperty::Color = 0x8, LayerProperty::Linetype = 0x10, LayerProperty::PrintColor = 0x20, LayerProperty::PrintWidth = 0x40, LayerProperty::ViewportVisible = 0x80, LayerProperty::ViewportColor = 0x100, LayerProperty::ViewportPrintColor = 0x200, LayerProperty::ViewportPrintWidth = 0x400, LayerProperty::RenderMaterial = 0x800, LayerProperty::Unused = 0x1000, LayerProperty::All = 0xFFFFFFFF } |
Static Public Member Functions | |
static int | Count (CRhinoDoc &doc) |
static bool | Delete (CRhinoDoc &doc, const wchar_t *state_name) |
static int | Find (CRhinoDoc &doc, const wchar_t *state_name) |
static int | Import (CRhinoDoc &doc, const wchar_t *filename) |
static bool | Names (CRhinoDoc &doc, ON_ClassArray< ON_wString > &state_names) |
static bool | Rename (CRhinoDoc &doc, const wchar_t *state_name, const wchar_t *new_name) |
static bool | Restore (CRhinoDoc &doc, const wchar_t *state_name, CRhinoLayerState::LayerProperty properties, const ON_UUID &viewport_id) |
static int | Save (CRhinoDoc &doc, const wchar_t *state_name, const ON_UUID &viewport_id) |
Description: Provides access to the document's saved layer states.
|
strong |
|
static |
Description: Returns the number of layer states saved in the document. Parameters: doc - [in] The document. Returns: The number of layer states.
|
static |
Description: Deletes a layer state saved in the document. Parameters: doc - [in] The document. state_name - [in] The name of the layer state to delete. Returns: true if successful, false otherwise.
|
static |
Description: Finds a layer state saved in the document. Parameters: doc - [in] The document. state_name - [in] The name of the layer state to find. Returns: The index of the layer state, -1 on failure.
|
static |
Description: Imports layer states from another .3dm file. Parameters: doc - [in] The document. filename - [in] The name of the .3dm file. Returns: The number of layer states imported from the file, -1 on failure.
|
static |
Description: Gets the names of the layer states saved in the document. Parameters: doc - [in] The document. state_names - [out] The names of the layer states. Returns: true if successful, false otherwise.
|
static |
Description: Renames a layer state saved in the document. Parameters: doc - [in] The document. state_name - [in] The name of the layer state to rename. new_name - [in] The new name. Returns: true if successful, false otherwise.
|
static |
Description: Restores a layer state saved in the document. Parameters: doc - [in] The document. state_name - [in] The name of the layer state to restore. properties - [in] The layer properties to restore. viewport_id - [in] If restoring the layer state to a layout or a details, then the id of the layout or detail view's viewport. Otherwise, just use ON_nil_uuid; Returns: true if successful, false otherwise.
|
static |
Description: Saves a new layer state to the document. Parameters: doc - [in] The document. state_name - [in] The name of the layer state to save. viewport_id - [in] If saving the layer state of a layout or a details, then the id of the layout or detail view's viewport. Otherwise, just use ON_nil_uuid; Returns: The index of the layer state, -1 on failure.