Class DialValueIndicator

    • Constructor Detail

      • DialValueIndicator

        public DialValueIndicator()
        Creates a new instance of DialValueIndicator.
      • DialValueIndicator

        public DialValueIndicator​(int datasetIndex)
        Creates a new instance of DialValueIndicator.
        Parameters:
        datasetIndex - the dataset index.
    • Method Detail

      • getDatasetIndex

        public int getDatasetIndex()
        Returns the index of the dataset from which this indicator fetches its current value.
        Returns:
        The dataset index.
        See Also:
        setDatasetIndex(int)
      • getAngle

        public double getAngle()
        Returns the angle for the anchor point. The angle is specified in degrees using the same orientation as Java's Arc2D class.
        Returns:
        The angle (in degrees).
        See Also:
        setAngle(double)
      • setAngle

        public void setAngle​(double angle)
        Sets the angle for the anchor point and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        angle - the angle (in degrees).
        See Also:
        getAngle()
      • setFrameAnchor

        public void setFrameAnchor​(org.jfree.ui.RectangleAnchor anchor)
        Sets the frame anchor and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        anchor - the anchor (null not permitted).
        See Also:
        getFrameAnchor()
      • setMaxTemplateValue

        public void setMaxTemplateValue​(java.lang.Number value)
        Sets the template value for the maximum size of the indicator bounds and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        value - the value (null permitted).
        Since:
        1.0.14
        See Also:
        getMaxTemplateValue()
      • setNumberFormat

        public void setNumberFormat​(java.text.NumberFormat formatter)
        Sets the formatter used to format the value and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        formatter - the formatter (null not permitted).
        See Also:
        getNumberFormat()
      • getFont

        public java.awt.Font getFont()
        Returns the font.
        Returns:
        The font (never null).
        See Also:
        getFont()
      • setFont

        public void setFont​(java.awt.Font font)
        Sets the font and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        font - the font (null not permitted).
      • getPaint

        public java.awt.Paint getPaint()
        Returns the paint.
        Returns:
        The paint (never null).
        See Also:
        setPaint(Paint)
      • setPaint

        public void setPaint​(java.awt.Paint paint)
        Sets the paint and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        paint - the paint (null not permitted).
        See Also:
        getPaint()
      • setInsets

        public void setInsets​(org.jfree.ui.RectangleInsets insets)
        Sets the insets and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        insets - the insets (null not permitted).
        See Also:
        getInsets()
      • setValueAnchor

        public void setValueAnchor​(org.jfree.ui.RectangleAnchor anchor)
        Sets the value anchor and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        anchor - the anchor (null not permitted).
        See Also:
        getValueAnchor()
      • setTextAnchor

        public void setTextAnchor​(org.jfree.ui.TextAnchor anchor)
        Sets the text anchor and sends a DialLayerChangeEvent to all registered listeners.
        Parameters:
        anchor - the anchor (null not permitted).
        See Also:
        getTextAnchor()
      • draw

        public void draw​(java.awt.Graphics2D g2,
                         DialPlot plot,
                         java.awt.geom.Rectangle2D frame,
                         java.awt.geom.Rectangle2D view)
        Draws the background to the specified graphics device. If the dial frame specifies a window, the clipping region will already have been set to this window before this method is called.
        Specified by:
        draw in interface DialLayer
        Parameters:
        g2 - the graphics device (null not permitted).
        plot - the plot (ignored here).
        frame - the dial frame (ignored here).
        view - the view rectangle (null not permitted).
      • equals

        public boolean equals​(java.lang.Object obj)
        Tests this instance for equality with an arbitrary object.
        Overrides:
        equals in class AbstractDialLayer
        Parameters:
        obj - the object (null permitted).
        Returns:
        A boolean.
      • clone

        public java.lang.Object clone()
                               throws java.lang.CloneNotSupportedException
        Returns a clone of this instance.
        Specified by:
        clone in interface org.jfree.util.PublicCloneable
        Overrides:
        clone in class AbstractDialLayer
        Returns:
        The clone.
        Throws:
        java.lang.CloneNotSupportedException - if some attribute of this instance cannot be cloned.