|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jvnet.substance.painter.decoration.ImageWrapperDecorationPainter
public abstract class ImageWrapperDecorationPainter
Implementation of SubstanceDecorationPainter
that uses brushed metal
painting on decoration areas.
Field Summary | |
---|---|
protected SubstanceDecorationPainter |
baseDecorationPainter
The base decoration painter - the colorized image tiles are painted over the painting of this painter. |
protected java.util.LinkedHashMap<java.lang.String,java.awt.Image> |
colorizedTileMap
Map of colorized tiles. |
protected java.awt.Image |
originalTile
Contains the original (not colorized) image of this painter. |
protected float |
textureAlpha
Alpha channel for the texture image (colorized tiles applied on top of the baseDecorationPainter painting). |
Constructor Summary | |
---|---|
ImageWrapperDecorationPainter()
Creates a new image wrapper decoration painter. |
Method Summary | |
---|---|
protected java.awt.Image |
getColorizedTile(SubstanceColorScheme scheme)
Returns a colorized image tile. |
void |
paintDecorationArea(java.awt.Graphics2D graphics,
java.awt.Component comp,
DecorationAreaType decorationAreaType,
int width,
int height,
SubstanceSkin skin)
Paints the decoration area. |
void |
setBaseDecorationPainter(SubstanceDecorationPainter baseDecorationPainter)
Sets the base decoration painter. |
void |
setPaintingSeparators(boolean isPaintingSeparators)
Deprecated. This method will be removed in version 6.0. Use SubstanceSkin.addOverlayPainter(SubstanceOverlayPainter, DecorationAreaType...)
with BottomLineOverlayPainter ,
TopLineOverlayPainter or
TopBezelOverlayPainter instead. Calling this method
in version 5.3 will not have any visual effect. |
void |
setTextureAlpha(float textureAlpha)
Sets the alpha channel for the image texture. |
protected void |
tileArea(java.awt.Graphics2D g,
java.awt.Component comp,
SubstanceColorScheme tileScheme,
int offsetTextureX,
int offsetTextureY,
int x,
int y,
int width,
int height)
Tiles the specified area with colorized version of the image tile. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.jvnet.substance.api.trait.SubstanceTrait |
---|
getDisplayName |
Field Detail |
---|
protected java.awt.Image originalTile
protected SubstanceDecorationPainter baseDecorationPainter
null
.
protected java.util.LinkedHashMap<java.lang.String,java.awt.Image> colorizedTileMap
protected float textureAlpha
baseDecorationPainter
painting).
Constructor Detail |
---|
public ImageWrapperDecorationPainter()
Method Detail |
---|
public void paintDecorationArea(java.awt.Graphics2D graphics, java.awt.Component comp, DecorationAreaType decorationAreaType, int width, int height, SubstanceSkin skin)
SubstanceDecorationPainter
paintDecorationArea
in interface SubstanceDecorationPainter
graphics
- Graphics context.comp
- Component.decorationAreaType
- Decoration area type. Must not be null
.width
- Width.height
- Height.skin
- Skin for painting the decoration area.protected void tileArea(java.awt.Graphics2D g, java.awt.Component comp, SubstanceColorScheme tileScheme, int offsetTextureX, int offsetTextureY, int x, int y, int width, int height)
baseDecorationPainter
has painted the area.
This method should respect the current textureAlpha
value.
g
- Graphic context.comp
- Component.tileScheme
- Scheme for the tile colorization.offsetTextureX
- X offset for the tiling.offsetTextureY
- Y offset for the tiling.x
- X coordinate of the tiling region.y
- Y coordinate of the tiling region.width
- Width of the tiling region.height
- Height of the tiling region.public void setBaseDecorationPainter(SubstanceDecorationPainter baseDecorationPainter)
baseDecorationPainter
- Base decoration painter.public void setTextureAlpha(float textureAlpha)
textureAlpha
- Alpha channel for the image texture.@Deprecated public void setPaintingSeparators(boolean isPaintingSeparators)
SubstanceSkin.addOverlayPainter(SubstanceOverlayPainter, DecorationAreaType...)
with BottomLineOverlayPainter
,
TopLineOverlayPainter
or
TopBezelOverlayPainter
instead. Calling this method
in version 5.3 will not have any visual effect.
isPaintingSeparators
- If true
, this painter will paint horizontal
separators on the bottom of each component passed to either
paintTitleBackground(Graphics2D, Component, DecorationAreaType, int, int, SubstanceSkin)
or
paintExtraBackground(Graphics2D, Container, Component, DecorationAreaType, int, int, SubstanceSkin)
.protected java.awt.Image getColorizedTile(SubstanceColorScheme scheme)
scheme
- Color scheme for the colorization.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |