class Horizontal extends Linear

Horizontal gradient fill.

Methods

__construct(int $length, ColorInterface $start, ColorInterface $end)

Constructs a linear gradient with overall gradient length, and start and end shades, which default to 0 and 255 accordingly.

from Linear
getColor(PointInterface $position)

Gets color of the fill for the given position.

from Linear
getStart()

No description

from Linear
getEnd()

No description

from Linear
int
getDistance(PointInterface $position)

Get the distance of the position relative to the beginning of the gradient.

Details

in Linear at line 46
final __construct(int $length, ColorInterface $start, ColorInterface $end)

Constructs a linear gradient with overall gradient length, and start and end shades, which default to 0 and 255 accordingly.

Parameters

int $length
ColorInterface $start
ColorInterface $end

in Linear at line 58
final ColorInterface getColor(PointInterface $position)

Gets color of the fill for the given position.

Parameters

PointInterface $position

Return Value

ColorInterface

See also

FillInterface::getColor

in Linear at line 76
final ColorInterface getStart()

Return Value

ColorInterface

in Linear at line 84
final ColorInterface getEnd()

Return Value

ColorInterface

at line 26
int getDistance(PointInterface $position)

Get the distance of the position relative to the beginning of the gradient.

Parameters

PointInterface $position

Return Value

int

See also

Linear::getDistance