< prev index next >
src/java.desktop/share/classes/sun/swing/DefaultLayoutStyle.java
Print this page
*** 30,40 ****
import javax.swing.LayoutStyle.ComponentPlacement;
import javax.swing.border.Border;
import javax.swing.plaf.UIResource;
/**
! * An implementation of <code>LayoutStyle</code> that returns 6 for related
* components, otherwise 12. This class also provides helper methods for
* subclasses.
*
*/
public class DefaultLayoutStyle extends LayoutStyle {
--- 30,40 ----
import javax.swing.LayoutStyle.ComponentPlacement;
import javax.swing.border.Border;
import javax.swing.plaf.UIResource;
/**
! * An implementation of {@code LayoutStyle} that returns 6 for related
* components, otherwise 12. This class also provides helper methods for
* subclasses.
*
*/
public class DefaultLayoutStyle extends LayoutStyle {
*** 131,141 ****
offset -= getButtonGap(source, position);
return Math.max(offset, 0);
}
/**
! * If <code>c</code> is a check box or radio button, and the border is
* not painted this returns the inset along the specified axis.
*/
public int getButtonGap(JComponent c, int position) {
String classID = c.getUIClassID();
if ((classID == "CheckBoxUI" || classID == "RadioButtonUI") &&
--- 131,141 ----
offset -= getButtonGap(source, position);
return Math.max(offset, 0);
}
/**
! * If {@code c} is a check box or radio button, and the border is
* not painted this returns the inset along the specified axis.
*/
public int getButtonGap(JComponent c, int position) {
String classID = c.getUIClassID();
if ((classID == "CheckBoxUI" || classID == "RadioButtonUI") &&
< prev index next >