CompositeBorderPainter
and DelegateBorderPainter
instead.@Deprecated public abstract class InnerDelegateBorderPainter extends java.lang.Object implements SubstanceBorderPainter
Modifier and Type | Field and Description |
---|---|
protected SubstanceBorderPainter |
delegate
Deprecated.
Mandatory delegate painter.
|
protected java.lang.String |
painterName
Deprecated.
Display name of
this painter. |
protected float |
shiftCoef
Deprecated.
Shift coefficient.
|
protected SubstanceConstants.ColorShiftKind |
shiftKind
Deprecated.
Color shift kind.
|
protected static LazyResettableHashMap<SubstanceColorScheme> |
shiftMap
Deprecated.
Map of shifted color schemes (to speed up the subsequent lookups).
|
Constructor and Description |
---|
InnerDelegateBorderPainter(java.lang.String painterName,
SubstanceBorderPainter delegate)
Deprecated.
Creates an inner painter.
|
InnerDelegateBorderPainter(java.lang.String painterName,
SubstanceBorderPainter delegate,
float shiftCoef,
SubstanceConstants.ColorShiftKind shiftKind)
Deprecated.
Creates an inner painter.
|
Modifier and Type | Method and Description |
---|---|
SubstanceBorderPainter |
getDelegate()
Deprecated.
Returns the painting delegate.
|
java.lang.String |
getDisplayName()
Deprecated.
Returns the display name of
this trait. |
SubstanceColorScheme |
getShiftScheme(SubstanceColorScheme orig)
Deprecated.
Retrieves a shifted color scheme.
|
boolean |
isPaintingInnerContour()
Deprecated.
Returns boolean indication whether this border painter is painting the
inner contours.
|
void |
paintBorder(java.awt.Graphics g,
java.awt.Component comp,
int width,
int height,
java.awt.Shape contour,
java.awt.Shape innerContour,
SubstanceColorScheme colorScheme1,
SubstanceColorScheme colorScheme2,
float cyclePos,
boolean useCyclePosAsInterpolation)
Deprecated.
Paints the control border.
|
protected java.lang.String painterName
this
painter.protected SubstanceBorderPainter delegate
protected float shiftCoef
protected SubstanceConstants.ColorShiftKind shiftKind
protected static final LazyResettableHashMap<SubstanceColorScheme> shiftMap
public InnerDelegateBorderPainter(java.lang.String painterName, SubstanceBorderPainter delegate)
painterName
- Painter display name.delegate
- Delegate painter.public InnerDelegateBorderPainter(java.lang.String painterName, SubstanceBorderPainter delegate, float shiftCoef, SubstanceConstants.ColorShiftKind shiftKind)
painterName
- Painter display name.delegate
- Delegate painter.shiftCoef
- Shift coefficient. Must be in 0.0-1.0 range.shiftKind
- Color shift kind.public java.lang.String getDisplayName()
SubstanceTrait
this
trait. This method is part
of officially supported API.getDisplayName
in interface SubstanceTrait
this
trait.public void paintBorder(java.awt.Graphics g, java.awt.Component comp, int width, int height, java.awt.Shape contour, java.awt.Shape innerContour, SubstanceColorScheme colorScheme1, SubstanceColorScheme colorScheme2, float cyclePos, boolean useCyclePosAsInterpolation)
SubstanceBorderPainter
paintBorder
in interface SubstanceBorderPainter
g
- Graphics.comp
- Component.width
- Width of a UI component.height
- Height of a UI component.contour
- Contour of a UI component.innerContour
- Inner contour of a UI component. May be ignored if the
specific implementation paints only the outside border.colorScheme1
- The first color scheme.colorScheme2
- The second color scheme.cyclePos
- Cycle position. Is used for rollover and pulsation effects.
Must be in 0..1 range.useCyclePosAsInterpolation
- Indicates the algorithm to use for computing various colors.
If true
, the cyclePos
is used to
interpolate colors between different color components of both
color schemes. If false
, the
cyclePos
is used to interpolate colors between
different color components of the first color scheme.public SubstanceColorScheme getShiftScheme(SubstanceColorScheme orig)
orig
- Original color scheme.public SubstanceBorderPainter getDelegate()
public boolean isPaintingInnerContour()
SubstanceBorderPainter
isPaintingInnerContour
in interface SubstanceBorderPainter
true
if this border painter is painting the inner
contours, false
otherwise.