Package org.zkoss.zul

Class DialModelRange

java.lang.Object
org.zkoss.zul.DialModelRange
All Implemented Interfaces:
Serializable

public class DialModelRange extends Object implements Serializable
Color range to be marked in DialModelScale.
Author:
henrichen
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    Return the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
    double
    Returns the lower bound in scale of this colored range.
    double
    Return the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
    Get the background color of the dial frame (in string as #RRGGBB).
    int[]
    Get the background color of the dial frame in int array (0: red, 1: green, 2:blue).
    double
    Returns the upper bound in scale of this colored range.
    void
    setInnerRadius(double radius)
    Sets the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
    void
    setLowerBound(double lower)
    Sets the lower bound in scale of this colored range.
    void
    setOuterRadius(double radius)
    Sets the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
    void
    setRange(double lower, double upper, String color, double innerRadius, double outerRadius)
    Setup the DailModel range.
    void
    Set the range color of the dial range.
    void
    setUpperBound(double upper)
    Sets the upper bound in scale of this colored range.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • setRange

      public void setRange(double lower, double upper, String color, double innerRadius, double outerRadius)
      Setup the DailModel range.
      Parameters:
      lower - the lower bound of the range in the scale.
      upper - the upper bound of the range in the scale.
      color - the color in #RRGGBB format (hexadecimal); default to blue.
      innerRadius - the inner radius percentage(0 ~ 1) of the range; default to 0.7.
      outerRadius - the outer radius percentage(0 ~ 1) of the range; default to 0.8;
    • setRangeColor

      public void setRangeColor(String color)
      Set the range color of the dial range.
      Parameters:
      color - in #RRGGBB format (hexadecimal).
    • getRangeColor

      public String getRangeColor()
      Get the background color of the dial frame (in string as #RRGGBB). null means default.
    • getRangeRGB

      public int[] getRangeRGB()
      Get the background color of the dial frame in int array (0: red, 1: green, 2:blue). null means default.
    • setInnerRadius

      public void setInnerRadius(double radius)
      Sets the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
      Parameters:
      radius - the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
    • getInnerRadius

      public double getInnerRadius()
      Return the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
      Returns:
      the inner radius percentage(0 ~ 1) of the dial range; default to 0.7.
    • setOuterRadius

      public void setOuterRadius(double radius)
      Sets the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
      Parameters:
      radius - the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
    • getOuterRadius

      public double getOuterRadius()
      Return the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
      Returns:
      the outer radius percentage(0 ~ 1) of the dial range; default to 0.8.
    • getLowerBound

      public double getLowerBound()
      Returns the lower bound in scale of this colored range.
      Returns:
      the lower bound in scale of this colored range.
    • setLowerBound

      public void setLowerBound(double lower)
      Sets the lower bound in scale of this colored range.
      Parameters:
      lower - the specified lower bound in the scale.
    • getUpperBound

      public double getUpperBound()
      Returns the upper bound in scale of this colored range.
      Returns:
      the upper bound in scale of this colored range.
    • setUpperBound

      public void setUpperBound(double upper)
      Sets the upper bound in scale of this colored range.
      Parameters:
      upper - the upper bound