public class Utilities extends java.lang.Object implements CSSProperties
ARC_HEIGHT, ARC_WIDTH, BACKGROUND_COLOR, BACKGROUND_IMAGE, BACKGROUND_RADIUS, BORDER_COLOR, BORDER_RADIUS, FILL_PAINT, FONT, FONT_FAMILY, FONT_SIZE, FONT_STYLE, FONT_WEIGHT, IMAGE, OPACITY, REGION_BACKGROUND, REGION_BACKGROUND_POSITION, REGION_BACKGROUND_RADIUS, REGION_BACKGROUND_SIZE, REGION_BORDER, SCALE_SHAPE, SCALE_X, SCALE_Y, SHAPE, STROKE_DASHARRAY, STROKE_DASHOFFSET, STROKE_LINECAP, STROKE_LINEJOIN, STROKE_MITERLIMIT, STROKE_PAINT, STROKE_TYPE, STROKE_WIDTH, TEXT_BOUNDS_TYPE, TEXT_FILL, TRANSLATE_X, TRANSLATE_Y, VISIBILITY
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
convertColor(javafx.scene.paint.Color color) |
static java.util.Map<java.lang.String,CSSProperty> |
extractProperties(javafx.scene.Node node)
Extract the properties of a Node.
|
static java.util.Set<java.lang.String> |
extractPseudoClasses(javafx.scene.Node node)
Extract the pseudo-classes of a Node.
|
static java.util.List<BackgroundWrapper> |
getPaintList(javafx.scene.layout.Region region,
javafx.scene.layout.Background background,
NodeConverter converter,
double opacity)
Return the list of BackgroundWrappers for a Region.
|
static java.util.List<BorderWrapper> |
getPaintList(javafx.scene.layout.Region region,
javafx.scene.layout.Border border)
Return the list of BorderWrappers for a Region.
|
static javafx.scene.text.FontPosture |
getPosture(javafx.scene.text.Font font)
Return the FontPosture of a JavaFX Font.
|
static java.lang.String |
getRelativePath(java.io.File baseDir,
java.io.File file,
boolean strict)
Return the path of a File relative to a directory.
|
static java.lang.String |
getScale(javafx.scene.transform.Scale scale) |
static javafx.scene.text.FontWeight |
getWeight(javafx.scene.text.Font font)
Return the FontWeight of a JavaFX Font.
|
static java.util.List<java.lang.String> |
splitString(java.lang.String string,
int partitionSize) |
public static java.lang.String convertColor(javafx.scene.paint.Color color)
public static javafx.scene.text.FontWeight getWeight(javafx.scene.text.Font font)
font
- the Fontpublic static javafx.scene.text.FontPosture getPosture(javafx.scene.text.Font font)
font
- the Fontpublic static java.util.Set<java.lang.String> extractPseudoClasses(javafx.scene.Node node)
node
- the Nodepublic static java.util.Map<java.lang.String,CSSProperty> extractProperties(javafx.scene.Node node)
node
- the Nodepublic static java.util.List<BackgroundWrapper> getPaintList(javafx.scene.layout.Region region, javafx.scene.layout.Background background, NodeConverter converter, double opacity)
region
- the Regionbackground
- the Backgroundconverter
- the NodeConverteropacity
- the opacitypublic static java.util.List<BorderWrapper> getPaintList(javafx.scene.layout.Region region, javafx.scene.layout.Border border)
region
- the Regionborder
- the Backgroundpublic static java.lang.String getScale(javafx.scene.transform.Scale scale)
public static java.util.List<java.lang.String> splitString(java.lang.String string, int partitionSize)
public static java.lang.String getRelativePath(java.io.File baseDir, java.io.File file, boolean strict)
baseDir
- the base directoryfile
- the Filestrict
- true if this will fall back to the absolute path of the File if the File is not under the base directoryCopyright © 2021, 2022, 2025 Herve Girod. All Rights Reserved. Documentation and source under the BSD 3-Clause licence