Module MaterialFX

Class AbstractMFXRippleGenerator<T extends IRipple>

java.lang.Object
javafx.scene.Node
javafx.scene.Parent
javafx.scene.layout.Region
io.github.palexdev.materialfx.effects.ripple.base.AbstractMFXRippleGenerator<T>
Type Parameters:
T - the types of ripple accepted by the generator
All Implemented Interfaces:
IRippleGenerator<T>, Styleable, EventTarget
Direct Known Subclasses:
MFXCircleRippleGenerator

public abstract class AbstractMFXRippleGenerator<T extends IRipple> extends Region implements IRippleGenerator<T>
Abstract class that defines all the properties and behaviors a RippleGenerator should have.

Also defines the style class ("mfx-ripple-generator") for all generators that extend this class.

When generating ripples, four are three important information:

- Region: the generator must have a reference to the Region in which it will generate ripples.

- Position: the generator must know where you want to generate the ripple, so x and y coordinates (positionFunction.

- Ripple type/shape: the generator must know what kind of ripple you want to generate (circle, rectangle...), rippleSupplier.

- Clip/Ripple Bounds: the generator should know the bounds beyond which the ripple must not go. In JavaFX to achieve such behavior there is the clip concept, clipSupplier.