Documentation of 'org.jfree.chart.util.DefaultShadowGenerator' Java class
DefaultShadowGenerator
org.jfree.chart.util

Class DefaultShadowGenerator

    • Constructor Summary

      Constructors 
      Constructor and Description
      DefaultShadowGenerator()
      Creates a new instance with default attributes.
      DefaultShadowGenerator(int size, java.awt.Color color, float opacity, int distance, double angle)
      Creates a new instance with the specified attributes.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int calculateOffsetX()
      Calculates the x-offset for drawing the shadow image relative to the source.
      int calculateOffsetY()
      Calculates the y-offset for drawing the shadow image relative to the source.
      java.awt.image.BufferedImage createDropShadow(java.awt.image.BufferedImage source)
      Creates and returns an image containing the drop shadow for the specified source image.
      boolean equals(java.lang.Object obj)
      Tests this object for equality with an arbitrary object.
      double getAngle()
      Returns the shadow offset angle (in radians).
      int getDistance()
      Returns the shadow offset distance.
      java.awt.Color getShadowColor()
      Returns the shadow color.
      float getShadowOpacity()
      Returns the shadow opacity.
      int getShadowSize()
      Returns the shadow size.
      int hashCode()
      Returns a hash code for this instance.
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultShadowGenerator

        public DefaultShadowGenerator()
        Creates a new instance with default attributes.
      • DefaultShadowGenerator

        public DefaultShadowGenerator(int size,
                                      java.awt.Color color,
                                      float opacity,
                                      int distance,
                                      double angle)
        Creates a new instance with the specified attributes.
        Parameters:
        size - the shadow size.
        color - the shadow color.
        opacity - the shadow opacity.
        distance - the shadow offset distance.
        angle - the shadow offset angle (in radians).
    • Method Detail

      • getShadowSize

        public int getShadowSize()
        Returns the shadow size.
        Returns:
        The shadow size.
      • getShadowColor

        public java.awt.Color getShadowColor()
        Returns the shadow color.
        Returns:
        The shadow color (never null).
      • getShadowOpacity

        public float getShadowOpacity()
        Returns the shadow opacity.
        Returns:
        The shadow opacity.
      • getDistance

        public int getDistance()
        Returns the shadow offset distance.
        Returns:
        The shadow offset distance (in Java2D units).
      • getAngle

        public double getAngle()
        Returns the shadow offset angle (in radians).
        Returns:
        The angle (in radians).
      • calculateOffsetX

        public int calculateOffsetX()
        Calculates the x-offset for drawing the shadow image relative to the source.
        Specified by:
        calculateOffsetX in interface ShadowGenerator
        Returns:
        The x-offset.
      • calculateOffsetY

        public int calculateOffsetY()
        Calculates the y-offset for drawing the shadow image relative to the source.
        Specified by:
        calculateOffsetY in interface ShadowGenerator
        Returns:
        The y-offset.
      • createDropShadow

        public java.awt.image.BufferedImage createDropShadow(java.awt.image.BufferedImage source)
        Creates and returns an image containing the drop shadow for the specified source image.
        Specified by:
        createDropShadow in interface ShadowGenerator
        Parameters:
        source - the source image.
        Returns:
        A new image containing the shadow.
      • equals

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

        public int hashCode()
        Returns a hash code for this instance.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        The hash code.

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.