LinearGradientBrush

Namespace: PP;

Inheritance hierarchy

Object

Brush

GradientBrush

LinearGradientBrush

Description

The LinearGradientBrush class implements the brush with linear gradient fill.

Syntax

PP.initClass(PP.LinearGradientBrush, PP.GradientBrush, "LinearGradientBrush");

Constructor

  Constructor name Brief description
LinearGradientBrush The LinearGradientBrush constructor creates an instance of the LinearGradientBrush class.

Properties

  Property name Brief description
Angle The Angle property determines linear gradient angle.
EndPoint The EndPoint property sets the last relative point of the gradient.
StartPoint The StartPoint property sets relative starting point of the gradient.

Methods

  Method name Brief description
applyMixToNode The applyMixToNode method applies the brush mixed color with linear gradient fill to the specified DOM element.
applyToCanvas The applyToCanvas method applies the linear gradient fill brush to the specified canvas.
applyToNode The applyToNode method applies the brush with linear gradient fill to the specified DOM element.
getMix The getMix method returns the linear fill brush obtained after mixing with the specified brush in the certain ratio.
getMixColor The getMixColor method returns color obtained after mixing of gradient colors in the certain ratio.
toCSSFormat The toCSSFormat method returns a string in the CSS format with settings of linear gradient fill brush.
toSVGFormat The toSVGFormat method applies brush to the specified SVG element.

Properties inherited from the GradientBrush class

  Property name Brief description
GradientStops The GradientStops property sets an array of transition points in a gradient.
GradientType The GradientType property determines brush gradient direction.

Properties inherited from the Brush class

  Property name Brief description
Enabled The Enabled property determines whether the brush can be applied to a component.
Opacity The Opacity property determines fill transparency.

Methods inherited from the class Brush

  Method name Brief description
applyMatrix The applyMatrix method applies a color matrix for the brush.

Properties inherited from the Object class

  Property name Brief description
Data The Data property associates a random object with this component.
Id The Id property sets component identifier.
Settings The Settings property sets the component parameters.

Methods inherited from the Object class

  Method name Brief description
clone The clone method creates a copy of object. It is not implemented in PP.Ui.Control.
dispose The dispose method deletes the component.
getTypeName The getTypeName method returns the name of the object type without the namespace, to which it belongs.

See also:

PP