com.smartgwt.client.widgets.drawing

## Class ColorStop

- java.lang.Object
- - com.smartgwt.client.core.JsObject
  - - com.smartgwt.client.core.DataClass
    - - com.smartgwt.client.core.RefDataClass
      - - com.smartgwt.client.widgets.drawing.ColorStop

- All Implemented Interfaces:
    com.google.gwt.event.shared.HasHandlers

      public class ColorStop
      extends RefDataClass

  An object containing properties that is used in Gradient types

- - ### Field Summary

    - ### Fields inherited from class com.smartgwt.client.core.RefDataClass

      `id`

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

      `factoryCreated, factoryProperties, readOnly`

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

      `jsObj`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ColorStop()`
    `ColorStop(com.google.gwt.core.client.JavaScriptObject jsObj)`
    `ColorStop(java.lang.String color, float offset)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getColor()` eg #ff0000 or red or rgb(255,0,0)
    `float` | `getOffset()` The relative offset for the color.
    `float` | `getOpacity()` 0 is transparent, 1 is fully opaque
    `static ColorStop` | `getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)`
    `void` | `setColor(java.lang.String color)` eg #ff0000 or red or rgb(255,0,0)
    `void` | `setOffset(float offset)` The relative offset for the color.
    `void` | `setOpacity(float opacity)` 0 is transparent, 1 is fully opaque

    - ### Methods inherited from class com.smartgwt.client.core.RefDataClass

      `getRef, getRef, internalSetID`

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

      `applyFactoryProperties, doAddHandler, fireEvent, getAttribute, getAttributeAsBoolean, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDouble, getAttributeAsDoubleArray, getAttributeAsFloat, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsLong, getAttributeAsMap, getAttributeAsObject, getAttributeAsRecord, getAttributeAsString, getAttributeAsStringArray, getAttributes, getHandlerCount, getReadOnly, isFactoryCreated, logConfiguration, 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, setReadOnly`

    - ### 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 Detail

    - #### ColorStop

          public ColorStop()

    - #### ColorStop

          public ColorStop(com.google.gwt.core.client.JavaScriptObject jsObj)

    - #### ColorStop

          public ColorStop(java.lang.String color,
                           float offset)

  - ### Method Detail

    - #### getOrCreateRef

          public static ColorStop getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)

    - #### setColor

          public void setColor(java.lang.String color)

      eg #ff0000 or red or rgb(255,0,0)
      Parameters:
        `color` -
      See Also:
        `CSSColor . Default value is null`

    - #### getColor

          public java.lang.String getColor()

      eg #ff0000 or red or rgb(255,0,0)
      Returns:
      See Also:
        `CSSColor`

    - #### setOffset

          public void setOffset(float offset)

      The relative offset for the color.
      Parameters:
        `offset` - Default value is 0.0

    - #### getOffset

          public float getOffset()

      The relative offset for the color.
      Returns:
        float

    - #### setOpacity

          public void setOpacity(float opacity)

      0 is transparent, 1 is fully opaque
      Parameters:
        `opacity` - Default value is 1.0

    - #### getOpacity

          public float getOpacity()

      0 is transparent, 1 is fully opaque
      Returns:
        float