Package com.luciad.view.lightspeed.style
Class TLspLabelBoxStyle.Builder<B extends TLspLabelBoxStyle.Builder<B>>
java.lang.Object
com.luciad.view.lightspeed.style.ALspStyle.Builder<B>
com.luciad.view.lightspeed.style.TLspLabelBoxStyle.Builder<B>
- Enclosing class:
TLspLabelBoxStyle
public static class TLspLabelBoxStyle.Builder<B extends TLspLabelBoxStyle.Builder<B>>
extends ALspStyle.Builder<B>
Builder for label box styles.
The default label box style has a padding of 2, a 1-pixel border and no fill.
- Since:
- 2012.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionCopies all properties from the given style.build()
Constructs a label style with the set parameters.Sets the background color.filled
(boolean aFilled) Indicate whether a background color should be drawn.frameColor
(Color aFrameColor) Sets the line color of the frame.frameThickness
(float aFrameThickness) Sets the line width of the frame, in pixels.Sets the halo color.haloThickness
(float aThickness) Sets the halo thickness in pixels.padding
(int aPadding) Sets the padding between the label and its frame.Methods inherited from class com.luciad.view.lightspeed.style.ALspStyle.Builder
equals, hashCode
-
Constructor Details
-
Builder
protected Builder()
-
-
Method Details
-
padding
Sets the padding between the label and its frame. The default padding is0
.- Parameters:
aPadding
- the padding, in pixels- Returns:
- this
-
frameThickness
Sets the line width of the frame, in pixels. The default is0
, which indicates that no frame should be drawn.- Parameters:
aFrameThickness
- the frame line width, in pixels- Returns:
- this
-
frameColor
Sets the line color of the frame. The default isColor.black
. This property only has effect ifframeThickness(float)
is not set to0
. IfframeThickness(float)
was not called yet, the frame thickness is set to1
.- Parameters:
aFrameColor
- the desired frame color- Returns:
- this
-
filled
Indicate whether a background color should be drawn. The default isfalse
.- Parameters:
aFilled
-true
if the background color should be drawn,false
otherwise.- Returns:
- this
-
fillColor
Sets the background color. This property only has effect iffilled(boolean)
is set totrue
.- Parameters:
aFillColor
- the desired background color- Returns:
- this
-
haloColor
Sets the halo color. This property is only used if the halo is enabled.- Parameters:
aColor
- the halo color- Returns:
this
- Throws:
IllegalArgumentException
-if aColor==null
- See Also:
-
haloThickness
Sets the halo thickness in pixels. Set to zero if halo should be disabled.- Parameters:
aThickness
- the thickness in pixels- Returns:
this
- See Also:
-
all
Copies all properties from the given style.- Specified by:
all
in classALspStyle.Builder<B extends TLspLabelBoxStyle.Builder<B>>
- Parameters:
aStyle
- the style to copy- Returns:
this
-
build
Constructs a label style with the set parameters.- Specified by:
build
in classALspStyle.Builder<B extends TLspLabelBoxStyle.Builder<B>>
- Returns:
- the new label style
-