public class CustomStageBuilder
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.awt.Dimension |
DIMENSION |
Constructor and Description |
---|
CustomStageBuilder() |
Modifier and Type | Method and Description |
---|---|
CustomStage |
build()
Produces the CustomStage object as for the definitions given by the user
|
CustomStageBuilder |
removeNavigationPane()
Deprecated.
this method does not need to be called from this builder class after v1.1.0
Removes the left navigation pane of the window
|
CustomStageBuilder |
setActionIcons(javafx.scene.image.Image close,
javafx.scene.image.Image minimize,
javafx.scene.image.Image maximize,
javafx.scene.image.Image restore)
Changes the default icons for the action buttons on Title-bar
|
CustomStageBuilder |
setButtonColor(java.lang.String color)
Changes the color of the close, minimize and maximize/restore buttons
|
CustomStageBuilder |
setButtonHoverColor(java.lang.String color)
Changes the color of the minimize and maximize/restore buttons on hover (close button's color won't change)
|
CustomStageBuilder |
setDimensions(double minWidth,
double minHeight,
double maxWidth,
double maxHeight)
Sets the maximum and minimum resizing values for the window.
|
CustomStageBuilder |
setIcon(java.lang.String path)
The icon for the window to be showed on taskbar
|
CustomStageBuilder |
setNavigationPane(NavigationType type,
javafx.scene.layout.Pane navigationPane)
Sets a static navigation pane (to the pointed location) attaching the pane given
|
CustomStageBuilder |
setStyleSheet(java.net.URL path)
Style the CustomStage as to the user given stylesheet
|
CustomStageBuilder |
setTitleColor(java.lang.String color)
Changes the color of the color in title-bar
|
CustomStageBuilder |
setWindowColor(java.lang.String color)
Changes the color of the window
|
CustomStageBuilder |
setWindowTitle(java.lang.String title)
Sets the title of the title-bar
|
public CustomStageBuilder() throws java.io.IOException
java.io.IOException
public CustomStageBuilder setWindowTitle(java.lang.String title)
title
- title for the windowpublic CustomStageBuilder setIcon(java.lang.String path)
path
- path of the imagepublic CustomStageBuilder setWindowColor(java.lang.String color)
color
- name/hex/rgb/rgba value of the colorpublic CustomStageBuilder setTitleColor(java.lang.String color)
color
- name/hex/rgb/rgba value of the colorpublic CustomStageBuilder setButtonColor(java.lang.String color)
color
- name/hex/rgb/rgba value of the colorpublic CustomStageBuilder setButtonHoverColor(java.lang.String color)
color
- name/hex/rgb/rgba value of the colorpublic CustomStageBuilder setActionIcons(@Nullable javafx.scene.image.Image close, @Nullable javafx.scene.image.Image minimize, @Nullable javafx.scene.image.Image maximize, @Nullable javafx.scene.image.Image restore)
close
- Icon for close buttonminimize
- Icon for minimize buttonmaximize
- Window maximize (maximize button) iconrestore
- Window restore (maximize button) iconpublic CustomStageBuilder setDimensions(double minWidth, double minHeight, double maxWidth, double maxHeight)
minWidth
- Minimum width of windowminHeight
- Minimum height of windowmaxWidth
- Maximum width of windowmaxHeight
- Maximum height of windowpublic CustomStageBuilder setStyleSheet(java.net.URL path)
path
- URL of the stylesheetpublic CustomStageBuilder removeNavigationPane()
public CustomStageBuilder setNavigationPane(NavigationType type, javafx.scene.layout.Pane navigationPane)
type
- where the navigationPane should be placed on the window (LEFT/RIGHT/TOP/BOTTOM)navigationPane
- root pane of the navigation (fxml file)public CustomStage build()