Class MatteDecorationPainter
- java.lang.Object
-
- org.pushingpixels.radiance.theming.api.painter.decoration.MatteDecorationPainter
-
- All Implemented Interfaces:
RadianceDecorationPainter,RadianceTrait
public class MatteDecorationPainter extends java.lang.Object implements RadianceDecorationPainter
Implementation ofRadianceDecorationPainterthat uses matte painting on decoration areas.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringDISPLAY_NAMEThe display name for the decoration painters of this class.private static intFLEX_POINT
-
Constructor Summary
Constructors Constructor Description MatteDecorationPainter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private voidfill(java.awt.Graphics2D graphics, ContainerColorTokens colorTokens, int offsetY, int x, int y, int width, int height)java.lang.StringgetDisplayName()Returns the display name ofthistrait.voidpaintDecorationArea(java.awt.Graphics2D graphics, java.awt.Component comp, RadianceThemingSlices.DecorationAreaType decorationAreaType, int width, int height, RadianceSkin skin)Paints the decoration area as a fully filled rectangle.voidpaintDecorationArea(java.awt.Graphics2D graphics, java.awt.Component comp, RadianceThemingSlices.DecorationAreaType decorationAreaType, java.awt.Shape outline, ContainerColorTokens colorTokens)Paints the decoration area as a specified shape.private voidpaintExtraBackground(java.awt.Graphics2D graphics, java.awt.Component comp, int width, int height, ContainerColorTokens colorTokens)private voidpaintTitleBackground(java.awt.Graphics2D graphics, int width, int height, ContainerColorTokens colorTokens)
-
-
-
Field Detail
-
DISPLAY_NAME
public static final java.lang.String DISPLAY_NAME
The display name for the decoration painters of this class.- See Also:
- Constant Field Values
-
FLEX_POINT
private static final int FLEX_POINT
- See Also:
- Constant Field Values
-
-
Method Detail
-
getDisplayName
public java.lang.String getDisplayName()
Description copied from interface:RadianceTraitReturns the display name ofthistrait. This method is part of officially supported API.- Specified by:
getDisplayNamein interfaceRadianceTrait- Returns:
- The display name of
thistrait.
-
paintDecorationArea
public void paintDecorationArea(java.awt.Graphics2D graphics, java.awt.Component comp, RadianceThemingSlices.DecorationAreaType decorationAreaType, int width, int height, RadianceSkin skin)Description copied from interface:RadianceDecorationPainterPaints the decoration area as a fully filled rectangle.- Specified by:
paintDecorationAreain interfaceRadianceDecorationPainter- Parameters:
graphics- Graphics context.comp- Component.decorationAreaType- Decoration area type. Must not benull.width- Width.height- Height.skin- Skin for painting the decoration area.
-
paintTitleBackground
private void paintTitleBackground(java.awt.Graphics2D graphics, int width, int height, ContainerColorTokens colorTokens)
-
paintExtraBackground
private void paintExtraBackground(java.awt.Graphics2D graphics, java.awt.Component comp, int width, int height, ContainerColorTokens colorTokens)
-
fill
private void fill(java.awt.Graphics2D graphics, ContainerColorTokens colorTokens, int offsetY, int x, int y, int width, int height)
-
paintDecorationArea
public void paintDecorationArea(java.awt.Graphics2D graphics, java.awt.Component comp, RadianceThemingSlices.DecorationAreaType decorationAreaType, java.awt.Shape outline, ContainerColorTokens colorTokens)Description copied from interface:RadianceDecorationPainterPaints the decoration area as a specified shape.- Specified by:
paintDecorationAreain interfaceRadianceDecorationPainter- Parameters:
graphics- Graphics context.comp- Component.decorationAreaType- Decoration area type. Must not benull.outline- Outline to paint.colorTokens- Color tokens for painting the outline.
-
-