PCrop

Crops the selected imported image.


Command constructor

PCrop(short cHandle, long xLocation, long yLocation);
short cHandle;
Handle to drag when cropping object:
Side handles:
kEdgeLeft
kEdgeRight
kEdgeTop

kEdgeBottom

Corner handles:
kEdgeLeftTop
kEdgeLeftBottom
kEdgeRightTop
kEdgeRightBottom
long xLocation;
x coordinate, relative to the current zero point, to which you want the specified part dragged in twips
long yLocation;
y coordinate, relative to the current zero point, to which you want a corner dragged in twips
Crop single images only. The PCrop command can crop only one image at a time; if more than one image is selected, the plug-in or script stops running.

Crop imported images only. The PCrop command can crop only imported images, not graphics drawn with the PBox, PLine, and POval commands or the respective drawing tools.

cHandle for transformed objects. (See illustration below.) If the selected object was skewed, rotated, or reflected, cHandle should correspond to the handle before the object was transformed. For example, leftTop always refers to the original left-top handle of an object, not to the handle that is currently the left-most top handle.

Layout view only. The PCrop command works only in layout view.

Example. The following example selects the first object drawn and drags the left-bottom handle to the horizontal and vertical coordinates (four inches and two inches, respectively).

PSelect(1);
PCrop(kEdgeLeftBottom, twips("4i"), twips("2i"));


See also

The PSelect command

The PGetCropRect query

Adobe PageMaker 6.5 Help > Graphics and Text Blocks > Cropping a Graphic


Copyright © 1996, Adobe Systems Incorporated. All rights reserved.

Comments or suggestions? Contact Adobe Developer Support