CImageView:new


The new method creates an instance of the CImageView class. You must call new before using any class methods or properties. Note that the object can also be created using new_imageview.

Syntax

Object = CImageView:new()

bullet.gif    On success, this method returns a reference to the new CImageView object.

bullet.gif    On failure, nil is returned.

Remarks

There are two additional ways to create a new CImageView without using this method:

bullet.gif    Use the Attach method to create a new CImageView attached to the top-most Image Window. Also see attach_imageview.

bullet.gif    Use the AttachFromList method to create a new CImageView by selecting from a list of all open Image Windows. Also see attachlist_imageview.

Note: This method's name uses all lower case to present it as the analog of the C++ new operator. Generally, the names of class methods begin with an uppercase letter but new and delete are different.

Example

V = CImageView:new()

-- create a new instance of V of the CImageView class.

  ...

-- other uses of the class go here, between new and delete.

V:delete()

-- deletes the object and its associated memory.

Related Topics

CImageView, Attach, AttachFromList, delete, new_imageview


Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics, Inc. All Rights Reserved.