- java.lang.Object
- 
- javafx.scene.layout.BackgroundFill
 
- 
 public final class BackgroundFill extends Object The fill and associated properties that direct how to fill the background of aRegion. Because BackgroundFill is an immutable object, it can safely be used in any cache, and can safely be reused among multiple Regions or multiple times in the same Region.All BackgroundFills are drawn in order. When applied to a Region with a defined shape, the corner radii are ignored. - Since:
- JavaFX 8.0
 
- 
- 
Constructor SummaryConstructors Constructor Description BackgroundFill(Paint fill, CornerRadii radii, Insets insets)Creates a new BackgroundFill with the specified fill, radii, and insets.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)PaintgetFill()The Paint to use for filling the background of theRegion.InsetsgetInsets()The Insets to use for this fill.CornerRadiigetRadii()The Radii to use for representing the four radii of the BackgroundFill.inthashCode()
 
- 
- 
- 
Constructor Detail- 
BackgroundFillpublic BackgroundFill(Paint fill, CornerRadii radii, Insets insets) Creates a new BackgroundFill with the specified fill, radii, and insets. Null values are acceptable, but default values will be used in place of any null value.- Parameters:
- fill- Any Paint. If null, the value Color.TRANSPARENT is used.
- radii- The corner Radii. If null, the value Radii.EMPTY is used.
- insets- The insets. If null, the value Insets.EMPTY is used.
 
 
- 
 - 
Method Detail- 
getFillpublic final Paint getFill() The Paint to use for filling the background of theRegion. This value will never be null.- Returns:
- the Paint to use for filling the background of the Region
 
 - 
getRadiipublic final CornerRadii getRadii() The Radii to use for representing the four radii of the BackgroundFill. Each corner can therefore be independently specified. This will never be null. The radii values will never be negative.- Returns:
- the Radii to use for representing the four radii of the BackgroundFill
 
 - 
getInsetspublic final Insets getInsets() The Insets to use for this fill. Each inset indicates at what distance from the Region's bounds the drawing should begin. The insets will never be null, but the values may be negative in order to position the border beyond the natural bounds (that is, (0, 0, width, height)) of the Region.- Returns:
- the Insets to use for this fill
 
 
- 
 
-