Package org.jfree.ui

Class StandardGradientPaintTransformer

    • Constructor Detail

      • StandardGradientPaintTransformer

        public StandardGradientPaintTransformer​(GradientPaintTransformType type)
        Creates a new transformer with the specified type.
        Parameters:
        type - the transform type (null not permitted).
    • Method Detail

      • getType

        public GradientPaintTransformType getType()
        Returns the type of transform.
        Returns:
        The type of transform (never null).
        Since:
        1.0.10
      • transform

        public GradientPaint transform​(GradientPaint paint,
                                       Shape target)
        Transforms a GradientPaint instance to fit the specified target shape.
        Specified by:
        transform in interface GradientPaintTransformer
        Parameters:
        paint - the original paint (null not permitted).
        target - the target shape (null not permitted).
        Returns:
        The transformed paint.
      • equals

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

        public int hashCode()
        Returns a hash code for this object.
        Overrides:
        hashCode in class Object
        Returns:
        A hash code.