public class MonologFXButton
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
MonologFXButton.Type
Type of button, with several built-in options and three custom ones.
|
Constructor and Description |
---|
MonologFXButton()
Default constructor for a MonologFX button.
|
Modifier and Type | Method and Description |
---|---|
javafx.scene.Node |
getIcon()
Returns the graphic file (if one is assigned) for this button.
|
java.lang.String |
getLabel()
Returns the appropriate button label according to the following rules:
If the developer specifies a label, it returns that text.
|
MonologFXButton.Type |
getType()
Returns the type of this button.
|
boolean |
isCancelButton()
Indicates if this button is designated as the "cancel" button.
|
boolean |
isDefaultButton()
Indicates if this button is designated as the "default" button.
|
void |
setCancelButton(boolean cancelButton)
Designates this button as the "cancel" button - or not.
|
void |
setDefaultButton(boolean defaultButton)
Designates this button as the "default" button - or not.
|
void |
setIcon(java.lang.String iconFile)
Sets the graphic for use on the button, either alone or with text.
|
void |
setLabel(java.lang.String label)
Sets the label text for the button.
|
void |
setType(MonologFXButton.Type type)
Sets the type of this button.
|
public MonologFXButton()
public MonologFXButton.Type getType()
MonologFXButton.Type
public void setType(MonologFXButton.Type type)
type
- MonologFXButton.Type designation.MonologFXButton.Type
public java.lang.String getLabel()
public void setLabel(java.lang.String label)
label
- String consisting of the desired button text.public javafx.scene.Node getIcon()
public void setIcon(java.lang.String iconFile)
iconFile
- String containing the location and name of a graphic file
(.png, .jpg) for use as an icon on the button face.ImageView
public boolean isDefaultButton()
public void setDefaultButton(boolean defaultButton)
defaultButton
- Boolean.public boolean isCancelButton()
public void setCancelButton(boolean cancelButton)
cancelButton
- Boolean.