![]() |
CNiCursors3D | ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Class |
Declared in: NiCursors3D.h |
Overview
CNiCursors3D encapsulates the interface to the Cursors property of a CNiGraph3D object, which allows you to access and remove cursors associated with the graph control. You use cursors to enable your users to identify specific points on your 3D graph plots.
Base Classes
Data Items
![]() |
short | Count | Returns the number of cursors in the collection. |
Constructors
![]() |
Default constructor. | ||
![]() |
CNiCursors3D( CWCursors3D_CI* pCustom, CNiInterface::ThreadAccess option ) |
Constructor that attaches to the specified CWCursors3D_CI pointer. | |
![]() |
CNiCursors3D( const CNiCursors3D& source ) |
Copy constructor. |
Destructors
Functions
![]() |
CNiCursor3D | Add() |
Adds a cursor to the collection and returns the new cursor. |
![]() |
static const IID & | GetIid() |
Returns the globally unique identifier (GUID) of the ActiveX interface to which this class connects. |
![]() |
CNiCursor3D | Item( long cursorIndex ) |
Returns the specified cursor from the collection. |
![]() |
CNiCursor3D | Returns the specified cursor from the collection. | |
![]() |
const CNiCursors3D & | Assignment operator. | |
![]() |
void | Remove( long cursorIndex ) |
Removes the specified cursor from the collection. |
![]() |
void | Removes the specified cursor from the collection. | |
![]() |
void | Removes all cursors from the collection. |
Examples
1. Set the snap mode and visibility of the first cursor on the graph.
CNiGraph graph; CNiCursor3D cursor = graph.Cursors.Item(1); cursor.SnapMode = CNiCursor3D::SnapNearestPlot; cursor.Visible = true;
2. Set the point style.
CNiGraph graph; graph.Cursors.Item(1).PointStyle = CNiCursor3D::WireframeCube;
3. Add an additional cursor to the graph and hide it.
CNiGraph graph; CNiCursor3D cursor = graph.Cursors.Add(); cursor.Visible = false;
4. Remove all cursors from the graph.
CNiGraph graph; graph.Cursors.RemoveAll();
5. Change the name of the first cursor.
CNiGraph graph; graph.Cursors.Item(1).Name = "Time";
Subsequent accesses to this cursor must now use "Time" for its name. For example,
graph.Cursors.Item("Time").Visible = true;