Home » openjdk-7 » sun » swing » [javadoc | source]
sun.swing
public class: DefaultLayoutStyle [javadoc | source]
java.lang.Object
   javax.swing.LayoutStyle
      sun.swing.DefaultLayoutStyle

Direct Known Subclasses:
    WindowsLayoutStyle, GnomeLayoutStyle

An implementation of LayoutStyle that returns 6 for related components, otherwise 12. This class also provides helper methods for subclasses.
Method from sun.swing.DefaultLayoutStyle Summary:
flipDirection,   getButtonGap,   getButtonGap,   getButtonGap,   getContainerGap,   getIndent,   getInstance,   getPreferredGap,   isLabelAndNonlabel
Methods from javax.swing.LayoutStyle:
getContainerGap,   getInstance,   getPreferredGap,   setInstance
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from sun.swing.DefaultLayoutStyle Detail:
 protected int flipDirection(int position) 
 public int getButtonGap(JComponent c,
    int position) 
    If c is a check box or radio button, and the border is not painted this returns the inset along the specified axis.
 protected int getButtonGap(JComponent source,
    int position,
    int offset) 
    For some look and feels check boxs and radio buttons typically don't paint the border, yet they have padding for a border. Look and feel guidelines generally don't include this space. Use this method to subtract this space from the specified components.
 protected int getButtonGap(JComponent source,
    JComponent target,
    int position,
    int offset) 
    For some look and feels check boxs and radio buttons typically don't paint the border, yet they have padding for a border. Look and feel guidelines generally don't include this space. Use this method to subtract this space from the specified components.
 public int getContainerGap(JComponent component,
    int position,
    Container parent) 
 protected int getIndent(JComponent c,
    int position) 
    Returns the amount to indent the specified component if it's a JCheckBox or JRadioButton. If the component is not a JCheckBox or JRadioButton, 0 will be returned.
 public static LayoutStyle getInstance() 
 public int getPreferredGap(JComponent component1,
    JComponent component2,
    ComponentPlacement type,
    int position,
    Container parent) 
 protected boolean isLabelAndNonlabel(JComponent c1,
    JComponent c2,
    int position) 
    Returns true if the classes identify a JLabel and a non-JLabel along the horizontal axis.