RhinoView
A RhinoView represents a single “window” display of a document. A view could contain one or many RhinoViewports (many in the case of Layout views with detail viewports). Standard Rhino modeling views have one viewport.
Inheritance Hierarchy
System.Object
Rhino.Display.RhinoView
Rhino.Display.RhinoPageView
Namespace: Rhino.Display
Assembly: RhinoCommon (in RhinoCommon.dll)
Syntax
public class RhinoView
The RhinoView type exposes the following members.
Properties
Name
Description
Public Property
Code Example
ActiveViewport
The ActiveViewport is the same as the MainViewport for standard RhinoViews. In a RhinoPageView, the active viewport may be the RhinoViewport of a child detail object. Most of the time, you will use ActiveViewport unless you explicitly need to work with the main viewport.
Public Property
ActiveViewportID
Returns viewport ID for the active viewport. Faster than ActiveViewport function when working with page views.
Public Property
Bounds
Gets the size and location of the view including its non-client elements, in pixels, relative to the parent control.
Public Property
ClientRectangle
Gets the rectangle that represents the client area of the view.
Public Property
DisplayPipeline
Gets the display pipeline used for this view.
Public Property
Document
Public Property
Static Member
EnableDrawing
Gets or sets the ‘drawing enabled’ flag. By default, drawing is enabled.
There are some rare situations where scripts want to disable drawing for a while.
Public Property
Floating
Floating state of RhinoView. if true, then the view will be in a floating frame window. Otherwise the view will be embedded in the main frame.
Public Property
Handle
Gets the window handle that this view is bound to.
Public Property
InDynamicViewChange
true if the view is being dynamically changed by mouse moves, arrow keys, trackballs, etc.
Public Property
MainViewport
A RhinoView contains a “main viewport” that fills the entire view client window. RhinoPageViews may also contain nested child RhinoViewports for implementing detail viewports. The MainViewport will always return this RhinoView’s m_vp.
Public Property
Maximized
Public Property
RealtimeDisplayMode
Gets the RealtimeDisplayMode active for this view. null if the view doesn’t have a RealtimeDisplayMode set.
Public Property
RuntimeSerialNumber
Public Property
ScreenRectangle
Gets the rectangle that represents the client area of the view in screen coordinates.
Public Property
Size
Gets or sets the size of the view
Public Property
TitleVisible
Visibility of the viewport title window.
Methods
Name
Description
Public Method
CaptureToBitmap.
Capture View contents to a bitmap.
Public Method
CaptureToBitmap(DisplayModeDescription)
Capture View contents to a bitmap using a display mode description to define how drawing is performed.
Public Method
CaptureToBitmap(DisplayPipelineAttributes)
Captures view contents to a bitmap using display attributes to define how drawing is performed.
Public Method
CaptureToBitmap(Size)
Capture View contents to a bitmap.
Public Method
CaptureToBitmap(Size, DisplayModeDescription)
Capture View contents to a bitmap using a display mode description to define how drawing is performed.
Public Method
CaptureToBitmap(Size, DisplayPipelineAttributes)
Capture View contents to a bitmap using display attributes to define how drawing is performed.
Public Method
Code Example
CaptureToBitmap(Boolean, Boolean, Boolean)
Captures the view contents to a bitmap allowing for visibility of grid and axes.
Public Method
CaptureToBitmap(Size, Boolean, Boolean, Boolean)
Captures a part of the view contents to a bitmap allowing for visibility of grid and axes.
Public Method
ClientToScreen(Point)
Public Method
ClientToScreen(Point2d)
Public Method
Close
Remove this View from Rhino. DO NOT attempt to use this instance of this class after calling Close.
Public Method
CreateShadedPreviewImage
Creates a bitmap preview image of model.
Public Method
CreateWireframePreviewImage
Creates a bitmap preview image of model.
Public Method
Equals
(Overrides Object.Equals(Object).)
Protected Method
Finalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public Method
Static Member
FromRuntimeSerialNumber
Get a RhinoView from it’s unique runtime serial number
Public Method
GetHashCode
(Overrides Object.GetHashCode..)
Public Method
GetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected Method
MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public Method
MouseCaptured
Returns whether or not the mouse is captured in this view.
Public Method
Code Example
Redraw
Redraws this view.
Public Method
ScreenToClient(Point)
Converts a point in screen coordinates to client coordinates for this view.
Public Method
ScreenToClient(Point2d)
Public Method
ShowToast(String)
Shows a temporary popup message in the lower right corner of the view
Public Method
ShowToast(String, Int32)
Shows a temporary popup message in the lower right corner of the view
Public Method
ShowToast(String, Int32, PointF)
Shows a temporary popup message in the lower right corner of the view
Public Method
SpeedTest
Public Method
ToString
Returns a string that represents the current object.
(Inherited from Object.)
Events
Name
Description
Public Event
Static Member
Create
Public Event
Static Member
Destroy
Public Event
Static Member
Modified
Public Event
Static Member
Rename
Public Event
Static Member
SetActive