001 package org.jdesktop.swingx.painter;
002
003 import org.jdesktop.swingx.BeanInfoSupport;
004 import org.jdesktop.swingx.editors.EnumPropertyEditor;
005
006 /**
007 * BeanInfo of AbstractLayoutPainter.
008 *
009 * @author Jan Stola
010 */
011 public class AbstractLayoutPainterBeanInfo extends BeanInfoSupport {
012
013 public AbstractLayoutPainterBeanInfo() {
014 super(AbstractLayoutPainter.class);
015 }
016
017 public AbstractLayoutPainterBeanInfo(Class clazz) {
018 super(clazz);
019 }
020
021 protected void initialize() {
022 setPropertyEditor(HorizontalAlignmentPropertyEditor.class, "horizontalAlignment");
023 setPropertyEditor(VerticalAlignmentPropertyEditor.class, "verticalAlignment");
024 }
025
026 public static final class HorizontalAlignmentPropertyEditor extends EnumPropertyEditor<AbstractLayoutPainter.HorizontalAlignment> {
027 public HorizontalAlignmentPropertyEditor() {
028 super(AbstractLayoutPainter.HorizontalAlignment.class);
029 }
030 }
031
032 public static final class VerticalAlignmentPropertyEditor extends EnumPropertyEditor<AbstractLayoutPainter.VerticalAlignment> {
033 public VerticalAlignmentPropertyEditor() {
034 super(AbstractLayoutPainter.VerticalAlignment.class);
035 }
036 }
037
038 }