E - component typeI - decoration typepublic abstract class AbstractDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>> extends java.lang.Object implements IDecoration<E,I>
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
defaultStateId
Default component state ID.
|
protected java.lang.Float |
opacity
Decoration opacity.
|
protected java.lang.Boolean |
section
Whether or not this decoration is applied only to a section of the component.
|
protected java.awt.Dimension |
size
Decoration size.
|
protected java.util.List<java.lang.String> |
states
Component states this decoration is describing separated by comma.
|
protected java.lang.Boolean |
visible
Whether or not decoration should be displayed.
|
STATES_SEPARATOR| Constructor and Description |
|---|
AbstractDecoration() |
| Modifier and Type | Method and Description |
|---|---|
I |
clone() |
java.lang.String |
getId() |
float |
getOpacity()
Returns decoration opacity.
|
java.awt.Dimension |
getPreferredSize()
Returns decoration preferred size.
|
java.util.List<java.lang.String> |
getStates()
Returns component states this decoration is describing.
|
boolean |
isSection()
Returns whether or not this decoration is applied only to a section of the component.
|
boolean |
isVisible()
Returns whether or not this decoration state provides any visible decoration.
|
I |
merge(I state) |
void |
setSection(boolean section)
Sets whether or not this decoration is applied only to a section of the component.
|
java.lang.String |
toString() |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetBorderInsets, paintprovideShapepublic static final java.lang.String defaultStateId
@XStreamAsAttribute @XStreamConverter(value=com.alee.utils.xml.ListToStringConverter.class) protected java.util.List<java.lang.String> states
@XStreamAsAttribute protected java.lang.Boolean visible
SpecificPainter.
In case this decoration is used by SectionPainter this only affects section visibility.@XStreamAsAttribute protected java.awt.Dimension size
@XStreamAsAttribute protected java.lang.Float opacity
SpecificPainter.
In case this decoration is used by SectionPainter this opacity is only applied to the section.protected transient java.lang.Boolean section
public java.lang.String getId()
getId in interface com.alee.api.Identifiablepublic java.util.List<java.lang.String> getStates()
IDecorationgetStates in interface IDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>>public boolean isVisible()
IDecorationisVisible in interface IDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>>public boolean isSection()
IDecorationisSection in interface IDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>>public void setSection(boolean section)
IDecorationsetSection in interface IDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>>section - whether or not this decoration is applied only to a section of the componentpublic float getOpacity()
public java.awt.Dimension getPreferredSize()
IDecorationgetPreferredSize in interface IDecoration<E extends javax.swing.JComponent,I extends AbstractDecoration<E,I>>public I merge(I state)
merge in interface com.alee.api.Mergeable<I extends AbstractDecoration<E,I>>public I clone()
clone in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object