All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jidesoft.swing.AlignmentSupport Maven / Gradle / Ivy

There is a newer version: 3.6.18
Show newest version
package com.jidesoft.swing;

/**
 * A general interface for alignment support. All JIDE components will implement this method
 * if it has the following methods. In standard Swing package, AbstractButton, JLabel, JTextField etc should implement this too.
 */
public interface AlignmentSupport {
    /**
     * Returns the horizontal alignment of the content.
     * {@code AbstractButton}'s default is {@code SwingConstants.CENTER},
     * but subclasses such as {@code JCheckBox} may use a different default.
     *
     * @return the horizontalAlignment property,
     *         one of the following values:
     *         
    *
  • {@code SwingConstants.RIGHT} *
  • {@code SwingConstants.LEFT} *
  • {@code SwingConstants.CENTER} *
  • {@code SwingConstants.LEADING} *
  • {@code SwingConstants.TRAILING} *
*/ int getHorizontalAlignment(); /** * Sets the horizontal alignment of the content. * {@code AbstractButton}'s default is {@code SwingConstants.CENTER}, * but subclasses such as {@code JCheckBox} may use a different default. * * @param alignment the alignment value, one of the following values: *
    *
  • {@code SwingConstants.RIGHT} *
  • {@code SwingConstants.LEFT} *
  • {@code SwingConstants.CENTER} *
  • {@code SwingConstants.LEADING} *
  • {@code SwingConstants.TRAILING} *
* @throws IllegalArgumentException if the alignment is not one of the * valid values */ void setHorizontalAlignment(int alignment); /** * Returns the vertical alignment of the content. * * @return the verticalAlignment property, one of the * following values: *
    *
  • {@code SwingConstants.CENTER} (the default) *
  • {@code SwingConstants.TOP} *
  • {@code SwingConstants.BOTTOM} *
*/ int getVerticalAlignment(); /** * Sets the vertical alignment of the content. * * @param alignment one of the following values: *
    *
  • {@code SwingConstants.CENTER} (the default) *
  • {@code SwingConstants.TOP} *
  • {@code SwingConstants.BOTTOM} *
* @throws IllegalArgumentException if the alignment is not one of the legal * values listed above */ void setVerticalAlignment(int alignment); }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy