ViewSize

Returns the width and height in pixels of the specified view.

Syntax

rhinoscriptsyntax.ViewSize (view=None)

rhinoscript.view.ViewSize (view=None)

Parameters

view

Optional.  String or Guid.  The title or identifier of the view.  If omitted, the current active view is used.

Returns

list

A zero-based, one-dimensional array containing two numbers identifying the width and height if successful

None

If not successful, or on error.

Example

import rhinoscriptsyntax as rs

size = rs.ViewSize()

if size:

    print "Width: ", size[0], " pixels."

    print "Height: ", size[1], " pixels."

Also See

ViewCameraLens

ViewCameraTarget

ViewCPlane

ViewDisplayModes

ViewProjection