Package net.infonode.gui.colorprovider
Class BackgroundPainterColorProvider
java.lang.Object
net.infonode.gui.colorprovider.AbstractColorProvider
net.infonode.gui.colorprovider.BackgroundPainterColorProvider
- All Implemented Interfaces:
Serializable
,ColorProvider
Finds the most suitable background color of a component.
If the component has a
ComponentPainter
that paint its background, like for example a shaped panel, the
color is taken from this painter, otherwise the component background color is used.- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BackgroundPainterColorProvider
The only instance of this class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the color obtained from the given component.protected Object
Methods inherited from class net.infonode.gui.colorprovider.AbstractColorProvider
getColor
-
Field Details
-
INSTANCE
The only instance of this class.
-
-
Method Details
-
getColor
Description copied from interface:ColorProvider
Returns the color obtained from the given component.- Specified by:
getColor
in interfaceColorProvider
- Overrides:
getColor
in classAbstractColorProvider
- Parameters:
component
- the component- Returns:
- the color obtained from the given component
-
readResolve
- Throws:
ObjectStreamException
-