A window that contains a single layout 'page'
Properties
Returns the active detail object. If no detail is active, or if the page is active, then null is returned.
Returns the id of the active detail. If no detail is active, or if the page is active, then Guid.Empty is returned.
Gets the active viewport. 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.
Overrides: RhinoView.ActiveViewport
ActiveViewportID
Returns viewport ID for the active viewport. Faster than ActiveViewport function when working with page views.
Bounds
Gets the size and location of the view including its non-client elements, in pixels, relative to the parent control.
ClientRectangle
Gets the rectangle that represents the client area of the view.
Gets and sets a brief description of the page view.
DisplayPipeline
Gets the display pipeline used for this view.
Document
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.
Handle
Gets the window handle that this view is bound to.
public nint Handle { get; }
InDynamicViewChange
true if the view is being dynamically changed by mouse moves, arrow keys, trackballs, etc.
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.
Maximized
Height of the page in the document's PageUnitSystem
Returns true if the page is active, rather than any detail view. This occurs when the MainViewport.Id == ActiveViewportID.
Gets or sets the runtime page number and updates the page number for all of the other pages. The first page has a value of 0.
Gets the number of page view groups this page view belongs to.
Width of the page in the document's PageUnitSystem
Returns the name of the layout's media, or paper (e.g. Letter, Legal, A1, etc.), used to determine the page width and page height.
Gets and sets the name of the layout's destination printer.
RealtimeDisplayMode
Gets the RealtimeDisplayMode active for this view. null if the view doesn't have a RealtimeDisplayMode set.
RuntimeSerialNumber
ScreenRectangle
Gets the rectangle that represents the client area of the view in screen coordinates.
Methods
Creates a detail view object that is displayed on this page and adds it to the document.
public DetailViewObject AddDetailView()
title,
The detail view title.
corner0,
Corners of the detail view in world coordinates.
corner1,
Corners of the detail view in world coordinates.
initialProjection
The defined initial projection type.
Returns: Newly created detail view on success, null on error.
Add this page view to a page view group.
Returns: The bitmap of the complete view.
CaptureToBitmap
Captures the view contents to a bitmap allowing for visibility of grid and axes.
Returns: A new bitmap.
CaptureToBitmap
Capture View contents to a bitmap using a display mode description to define how drawing is performed.
Returns: A new bitmap.
CaptureToBitmap
Captures view contents to a bitmap using display attributes to define how drawing is performed.
Returns: A new bitmap.
CaptureToBitmap
Captures a part of the view contents to a bitmap allowing for visibility of grid and axes.
Returns: A new bitmap.
CaptureToBitmap
Capture View contents to a bitmap using a display mode description to define how drawing is performed.
Returns: A new bitmap.
CaptureToBitmap
Capture View contents to a bitmap using display attributes to define how drawing is performed.
public Bitmap CaptureToBitmap()
size,
The width and height of the returned bitmap.
attributes
The specific display mode attributes.
Returns: A new bitmap.
CaptureToBitmap
Capture View contents to a bitmap.
Returns: The bitmap of the specified part of the view.
Close
Remove this View from Rhino. DO NOT attempt to use this instance of this class after calling Close.
Returns: true on success
CreateShadedPreviewImage
Creates a bitmap preview image of model.
public bool CreateShadedPreviewImage()
imagePath,
[in] The name of the bitmap file to create. The extension of the imagePath controls the format of the bitmap file created (BMP, TGA, JPG, PCX, PNG, TIF).
size,
[in] The width and height of the bitmap in pixels.
ignoreHighlights,
true if highlighted elements should be drawn normally.
drawConstructionPlane,
true if the CPlane should be drawn.
useGhostedShading
true if ghosted shading (partially transparent shading) should be used.
Returns: true if successful.
CreateWireframePreviewImage
Creates a bitmap preview image of model.
public bool CreateWireframePreviewImage()
imagePath,
[in] The name of the bitmap file to create. The extension of the imagePath controls the format of the bitmap file created (BMP, TGA, JPG, PCX, PNG, TIF).
size,
[in] The width and height of the bitmap in pixels.
ignoreHighlights,
true if highlighted elements should be drawn normally.
drawConstructionPlane
true if the CPlane should be drawn.
Returns: true if successful.
Copies a page view.
Returns: The new page view if successful, null otherwise.
Overrides: Object.Equals
Gets a list of the detail view objects associated with this layout.
Returns: An array of detail view objects if successful, an empty array if the layout has no details.
GetHashCode
Overrides: Object.GetHashCode
Gets an array of page view group indices this page view belongs to.
Returns: An array of page view group indices if successful, otherwise an empty array.
Creates a preview image of the page.
Returns: A bitmap if successful, null otherwise.
Determines if this page view belongs in a page view group.
Returns: True if the page view belongs in the page view group, otherwise false.
MouseCaptured
Returns whether or not the mouse is captured in this view.
Returns: true if captured, false otherwise.
Gets this page view's sort index within a page view group. The sort index determines the order of the page view among the other members of the group, independent of the document page (view-table) order.
Returns: The zero-based sort index, or RhinoMath.UnsetIntIndex when the page view is not in the group or the group is unsorted (uses page-number order).
Redraw
Redraws this view.
public void Redraw()
Remarks: If you change something in "this" view like the projection, construction plane, background bitmap, etc., then you need to call RhinoView.Redraw() to redraw "this" view./ The other views will not be changed. If you change something in the document (like adding new geometry to the model), then you need to call RhinoDoc.Views.Redraw() to redraw all the views.
RedrawOverlays
Redraws this view without regenerating its contents, when possible.
public void RedrawOverlays()
Remarks: Use this when only what display conduits draw in the DrawOverlay channel has changed. If nothing in the document or view has changed since the last frame, the previously captured frame is reused and only the overlays are drawn on top of it, which is much faster than RhinoView.Redraw() for expensive scenes such as layouts with many details. If something has changed, the view is fully redrawn, the same as RhinoView.Redraw().
Removes this page view to all page view groups.
public void RemoveFromAllageViewGroups()
Removes this page view to a page view group.
ScreenToClient
Converts a point in screen coordinates to client coordinates for this view.
Returns: A 2D point in client coordinates.
Sets the active detail.
Returns: true if successful, false otherwise.
Sets the active detail.
Returns: true if successful, false otherwise.
Deactivates the active details and sets the page view as active.
public void SetPageAsActive()
Sets this page view's sort index (position) within a page view group, repositioning it among the group's members and renumbering the rest so the group stays contiguously ordered. A sort index at or beyond the member count moves the page view to the end. If the page view is not yet in the group, it is added.
ShowToast
Shows a temporary popup message in the lower right corner of the view
[CLSCompliant(false)]
public uint ShowToast()
message,
The message to be shown
textHeight,
The height of the message
location
The location of the message
Returns: The runtime serial number of the view toast
ShowToast
Shows a temporary popup message in the lower right corner of the view
Returns: The runtime serial number of the view toast
ShowToast
Shows a temporary popup message in the lower right corner of the view
Returns: The runtime serial number of the view toast