PHP Class Neos\Media\Domain\Model\Adjustment\CropImageAdjustment

Inheritance: extends AbstractImageAdjustment
Show file Open project: neos/neos-development-collection

Protected Properties

Property Type Description
$height integer
$position integer
$width integer
$x integer
$y integer

Public Methods

Method Description
applyToImage ( Imagine\Image\ImageInterface $image ) : Imagine\Image\ImageInterface Applies this adjustment to the given Imagine Image object
canBeApplied ( Imagine\Image\ImageInterface $image ) : boolean Check if this Adjustment can or should be applied to its ImageVariant.
getHeight ( ) : integer Returns height
getWidth ( ) : integer Returns width
getX ( ) : integer Returns x
getY ( ) : integer Returns y
refit ( Neos\Media\Domain\Model\ImageInterface $image ) : void Refits the crop proportions to be the maximum size within the image boundaries.
setHeight ( integer $height ) : void Sets height
setWidth ( integer $width ) : void Sets width
setX ( integer $x ) : void Sets x
setY ( integer $y ) : void Sets y

Method Details

applyToImage() public method

Applies this adjustment to the given Imagine Image object
public applyToImage ( Imagine\Image\ImageInterface $image ) : Imagine\Image\ImageInterface
$image Imagine\Image\ImageInterface
return Imagine\Image\ImageInterface

canBeApplied() public method

Check if this Adjustment can or should be applied to its ImageVariant.
public canBeApplied ( Imagine\Image\ImageInterface $image ) : boolean
$image Imagine\Image\ImageInterface
return boolean

getHeight() public method

Returns height
public getHeight ( ) : integer
return integer

getWidth() public method

Returns width
public getWidth ( ) : integer
return integer

getX() public method

Returns x
public getX ( ) : integer
return integer

getY() public method

Returns y
public getY ( ) : integer
return integer

refit() public method

Refits the crop proportions to be the maximum size within the image boundaries.
public refit ( Neos\Media\Domain\Model\ImageInterface $image ) : void
$image Neos\Media\Domain\Model\ImageInterface
return void

setHeight() public method

Sets height
public setHeight ( integer $height ) : void
$height integer
return void

setWidth() public method

Sets width
public setWidth ( integer $width ) : void
$width integer
return void

setX() public method

Sets x
public setX ( integer $x ) : void
$x integer
return void

setY() public method

Sets y
public setY ( integer $y ) : void
$y integer
return void

Property Details

$height protected property

protected int $height
return integer

$position protected property

protected int $position
return integer

$width protected property

protected int $width
return integer

$x protected property

protected int $x
return integer

$y protected property

protected int $y
return integer