com.alee.laf.separator.AbstractSeparatorPainter Maven / Gradle / Ivy
package com.alee.laf.separator;
import com.alee.painter.decoration.AbstractDecorationPainter;
import com.alee.painter.decoration.DecorationState;
import com.alee.painter.decoration.IDecoration;
import javax.swing.*;
import javax.swing.plaf.SeparatorUI;
import java.util.List;
/**
* Abstract painter for {@link JSeparator} component.
*
* @param component type
* @param component UI type
* @param decoration type
* @author Alexandr Zernov
* @author Mikle Garin
*/
public abstract class AbstractSeparatorPainter>
extends AbstractDecorationPainter implements IAbstractSeparatorPainter
{
@Override
public List getDecorationStates ()
{
final List states = super.getDecorationStates ();
states.add ( component.getOrientation () == SwingConstants.HORIZONTAL ? DecorationState.horizontal : DecorationState.vertical );
return states;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy