CImageView:Attach
The Attach method attaches the top most window (an Image window) to the script and creates a new CImageView object for it.
NewImageView_Object = CImageView:Attach() where |
NewImageView_Object is a new CImageView object. On failure, nil is returned.
Use Attach to run the script on the top-most Image window. To do this, bring the target window to the top of the stack and run the script using the [!] button on the main toolbar.
Note: This method creates a new CImageView object so the new constructor should not be called for this object.
Suppose the script works with an image set displayed in the top-most window. The following script attaches the top-most window (an Image window) to the script and selects the 2nd image from the set:
|
-- attach the existing Image window |
|
-- get a pointer to the 2nd image |