Package com.smartgwt.client.widgets.drawing

# Class LinearGradient

java.lang.Object
com.smartgwt.client.core.JsObject
com.smartgwt.client.core.DataClass
com.smartgwt.client.widgets.drawing.Gradient
com.smartgwt.client.widgets.drawing.LinearGradient

All Implemented Interfaces:
  `HasHandlers`

public class LinearGradient extends Gradient
Definition of a linear gradient between two points, (`x1`, `y1`) and (`x2`, `y2`).

- ## Field Summary

  ### Fields inherited from class com.smartgwt.client.core.DataClass

  `factoryCreated, factoryProperties`

  ### Fields inherited from class com.smartgwt.client.core.JsObject

  `jsObj`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `LinearGradient()`
  `LinearGradient(JavaScriptObject jsObj)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static LinearGradient`
  `getOrCreateRef(JavaScriptObject jsObj)`
  `String`
  `getX1()`
  X coordinate of the start point.
  `String`
  `getX2()`
  X coordinate of the end point.
  `String`
  `getY1()`
  Y coordinate of the start point.
  `String`
  `getY2()`
  Y coordinate of the end point.
  `LinearGradient`
  `setX1(String x1)`
  X coordinate of the start point.
  `LinearGradient`
  `setX2(String x2)`
  X coordinate of the end point.
  `LinearGradient`
  `setY1(String y1)`
  Y coordinate of the start point.
  `LinearGradient`
  `setY2(String y2)`
  Y coordinate of the end point.

  ### Methods inherited from class com.smartgwt.client.widgets.drawing.Gradient

  `getColorStops, getEndColor, getId, getStartColor, setColorStops, setEndColor, setId, setStartColor`

  ### Methods inherited from class com.smartgwt.client.core.DataClass

  `applyFactoryProperties, doAddHandler, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsDoubleArray, getAttributeAsElement, getAttributeAsFloat, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsLong, getAttributeAsMap, getAttributeAsObject, getAttributeAsRecord, getAttributeAsString, getAttributeAsStringArray, getAttributes, getHandlerCount, isFactoryCreated, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttributeAsJavaObject, setFactoryCreated`

  ### Methods inherited from class com.smartgwt.client.core.JsObject

  `equals, getJsObj, hashCode, isCreated, setJavaScriptObject, setJsObj`

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### LinearGradient

    public LinearGradient()

  - ### LinearGradient

    public LinearGradient(JavaScriptObject jsObj)

- ## Method Details

  - ### getOrCreateRef

    public static LinearGradient getOrCreateRef(JavaScriptObject jsObj)

  - ### setX1

    public LinearGradient setX1(String x1)
    X coordinate of the start point. This can be a number or a percentage of the width of the bounding box of the DrawItem to which it is applied.
    Parameters:
      `x1` - New x1 value. Default value is null
    Returns:
      `LinearGradient` instance, for chaining setter calls

  - ### getX1

    public String getX1()
    X coordinate of the start point. This can be a number or a percentage of the width of the bounding box of the DrawItem to which it is applied.
    Returns:
      Current x1 value. Default value is null

  - ### setX2

    public LinearGradient setX2(String x2)
    X coordinate of the end point. This can be a number or a percentage of the width of the bounding box of the DrawItem to which it is applied.
    Parameters:
      `x2` - New x2 value. Default value is null
    Returns:
      `LinearGradient` instance, for chaining setter calls

  - ### getX2

    public String getX2()
    X coordinate of the end point. This can be a number or a percentage of the width of the bounding box of the DrawItem to which it is applied.
    Returns:
      Current x2 value. Default value is null

  - ### setY1

    public LinearGradient setY1(String y1)
    Y coordinate of the start point. This can be a number or a percentage of the height of the bounding box of the DrawItem to which it is applied.
    Parameters:
      `y1` - New y1 value. Default value is null
    Returns:
      `LinearGradient` instance, for chaining setter calls

  - ### getY1

    public String getY1()
    Y coordinate of the start point. This can be a number or a percentage of the height of the bounding box of the DrawItem to which it is applied.
    Returns:
      Current y1 value. Default value is null

  - ### setY2

    public LinearGradient setY2(String y2)
    Y coordinate of the end point. This can be a number or a percentage of the height of the bounding box of the DrawItem to which it is applied.
    Parameters:
      `y2` - New y2 value. Default value is null
    Returns:
      `LinearGradient` instance, for chaining setter calls

  - ### getY2

    public String getY2()
    Y coordinate of the end point. This can be a number or a percentage of the height of the bounding box of the DrawItem to which it is applied.
    Returns:
      Current y2 value. Default value is null