CImageView:GetCursorPos CImageView:GetCursorStyle

CImageView:GetCursorRect


The GetCursorRect method returns the extent of the image cursor in the CImageView. This function returns the rectangle limits in pixel coordinates.

Syntax

CRect = CImageView:GetCursorRect()

    This returns a CRect containing the xmin, xmax, ymin, and ymax values in pixel coordinates.

    On success, this method returns a new CRect object.

    On failure, this method returns nil.

Example

Assume that a CImageView object named V exists and wraps an image window. The following script fragment sets the image cursor to an x-range of 100:200 and a y-range of 300:500:

 

R = V:GetCursorRect()

-- retrieve the image cursor

Printf("%lg:%lg, %lg:%lg", R )

-- print the image cursor limits.

Related Topics

CImageView, SetCursorRect, SetCursorExtent, CRect, Image Coordinate System, Subpixel Coordinate Definition