|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jvnet.substance.shaper.BaseButtonShaper
org.jvnet.substance.shaper.StandardButtonShaper
public class StandardButtonShaper
Button shaper that returns buttons with completely rounded corners (ala Mac 10.4). This class is part of officially supported API.
| Constructor Summary | |
|---|---|
StandardButtonShaper()
|
|
| Method Summary | |
|---|---|
javax.swing.border.Border |
getButtonBorder(javax.swing.AbstractButton button)
Returns the border for the specified button. |
java.awt.geom.GeneralPath |
getButtonOutline(javax.swing.AbstractButton button,
java.awt.Insets insets,
int width,
int height,
boolean isInner)
Returns the outline path for the specified button. |
float |
getCornerRadius(javax.swing.AbstractButton button,
java.awt.Insets insets)
Returns the corner radius of the specified button. |
java.lang.String |
getDisplayName()
Returns the display name of this trait. |
java.awt.Dimension |
getPreferredSize(javax.swing.AbstractButton button,
java.awt.Dimension uiPreferredSize)
Returns the preferred size for the specified button. |
boolean |
isProportionate()
Returns the boolean indication whether the shaper should maintain button proportions on the resize. |
static boolean |
isRoundButton(javax.swing.AbstractButton button)
Returns indication whether the specified button should be drawn with completely round corners. |
| Methods inherited from class org.jvnet.substance.shaper.BaseButtonShaper |
|---|
getButtonOutline, getButtonOutline, getButtonOutline |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StandardButtonShaper()
| Method Detail |
|---|
public java.lang.String getDisplayName()
SubstanceTraitthis trait. This method is part
of officially supported API.
getDisplayName in interface SubstanceTraitgetDisplayName in interface SubstanceButtonShaperthis trait.
public java.awt.geom.GeneralPath getButtonOutline(javax.swing.AbstractButton button,
java.awt.Insets insets,
int width,
int height,
boolean isInner)
SubstanceButtonShaper
getButtonOutline in interface SubstanceButtonShaperbutton - A button.insets - Button insets.width - Button width.height - Button height.isInner - Indication whether the returned outline is used for the inner
contour.
public javax.swing.border.Border getButtonBorder(javax.swing.AbstractButton button)
SubstanceButtonShaper
getButtonBorder in interface SubstanceButtonShaperbutton - A button.
public java.awt.Dimension getPreferredSize(javax.swing.AbstractButton button,
java.awt.Dimension uiPreferredSize)
SubstanceButtonShaper
getPreferredSize in interface SubstanceButtonShaperbutton - A button.uiPreferredSize - Preferred size of the button under the regular conditions
(plain rectangular button).
public static boolean isRoundButton(javax.swing.AbstractButton button)
button - A button.
true if the specified button should be drawn with
completely round corners, false otherwise.public boolean isProportionate()
SubstanceButtonShaper
isProportionate in interface SubstanceButtonShapertrue if this shaper should maintain
button proportions on the resize, false otherwise.
public float getCornerRadius(javax.swing.AbstractButton button,
java.awt.Insets insets)
RectangularButtonShaper
getCornerRadius in interface RectangularButtonShaperbutton - Button.insets - Button insets.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||