Class Font.Builder
- java.lang.Object
-
- com.hybris.cockpitng.components.visjs.network.data.Font.Builder
-
- Enclosing class:
- Font
public static class Font.Builder extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Fontbuild()Font.BuilderwithAlign(java.lang.String align)Align of a label.Font.BuilderwithBackground(java.lang.String background)When color's value is provided then background rectangle will be drawn behind a label in the given color.Font.BuilderwithBold(FontMode bold)Represents details for font decoration: bold.Font.BuilderwithBoldital(FontMode boldital)Represents details for font decoration: boldital.Font.BuilderwithColor(java.lang.String color)Color of label text.Font.BuilderwithFace(java.lang.String face)Font face of label text.Font.BuilderwithItal(FontMode ital)Represents details for font decoration: ital.Font.BuilderwithMono(FontMode mono)Represents details for monospaced font decoration.Font.BuilderwithMulti(java.lang.Boolean multi)If false then label is treated as a pure text.Font.BuilderwithSize(java.lang.Integer size)Size of label text.Font.BuilderwithStrokeColor(java.lang.String strokeColor)A color of stroke, assuming that strokeWidth is positive.Font.BuilderwithStrokeWidth(java.lang.Integer strokeWidth)Alternative for background rectangle.Font.BuilderwithVadjust(java.lang.String vadjust)Font specific correction of the vertical positioning.
-
-
-
Method Detail
-
withColor
public Font.Builder withColor(java.lang.String color)
Color of label text. Default value is #343434.
-
withSize
public Font.Builder withSize(java.lang.Integer size)
Size of label text. Default value is 14.
-
withFace
public Font.Builder withFace(java.lang.String face)
Font face of label text. Default value is arial.
-
withBackground
public Font.Builder withBackground(java.lang.String background)
When color's value is provided then background rectangle will be drawn behind a label in the given color. Default value is null.
-
withStrokeWidth
public Font.Builder withStrokeWidth(java.lang.Integer strokeWidth)
Alternative for background rectangle. If positive value is provided then a stroke will be drawn. Default value is 0.
-
withStrokeColor
public Font.Builder withStrokeColor(java.lang.String strokeColor)
A color of stroke, assuming that strokeWidth is positive. Default value is #ffffff.
-
withAlign
public Font.Builder withAlign(java.lang.String align)
Align of a label. Possible values are "left" and "center". Default value is center.
-
withVadjust
public Font.Builder withVadjust(java.lang.String vadjust)
Font specific correction of the vertical positioning. Default value is 0
-
withMulti
public Font.Builder withMulti(java.lang.Boolean multi)
If false then label is treated as a pure text. If true then label may have multi-font, with bold, italic, and it will be interpreted as html. Default value is false.
-
withBold
public Font.Builder withBold(FontMode bold)
Represents details for font decoration: bold.
-
withItal
public Font.Builder withItal(FontMode ital)
Represents details for font decoration: ital.
-
withBoldital
public Font.Builder withBoldital(FontMode boldital)
Represents details for font decoration: boldital.
-
withMono
public Font.Builder withMono(FontMode mono)
Represents details for monospaced font decoration.
-
build
public Font build()
-
-