Package io.scanbot.sdk.ui_v2.common
Class PolygonStyle
-
- All Implemented Interfaces:
-
android.os.Parcelable
public final class PolygonStyle implements Parcelable
Configuration of the polygon appearance.
-
-
Field Summary
Fields Modifier and Type Field Description private ScanbotColorstrokeColorprivate ScanbotColorfillColorprivate DoublestrokeWidthprivate DoublecornerRadius
-
Constructor Summary
Constructors Constructor Description PolygonStyle(Map<String, Object> source)PolygonStyle(JSONObject json)PolygonStyle(ScanbotColor strokeColor, ScanbotColor fillColor, Double strokeWidth, Double cornerRadius)
-
Method Summary
Modifier and Type Method Description final ScanbotColorgetStrokeColor()The color of the polygon outline. final UnitsetStrokeColor(ScanbotColor strokeColor)The color of the polygon outline. final ScanbotColorgetFillColor()The fill color of the polygon. final UnitsetFillColor(ScanbotColor fillColor)The fill color of the polygon. final DoublegetStrokeWidth()The width of the polygon outline in dp. final UnitsetStrokeWidth(Double strokeWidth)The width of the polygon outline in dp. final DoublegetCornerRadius()The corner radius of the polygon in dp. final UnitsetCornerRadius(Double cornerRadius)The corner radius of the polygon in dp. final JSONObjecttoJson(ToJsonConfiguration config)final PolygonStyleclone()final static PolygonStyledefault()-
-
Constructor Detail
-
PolygonStyle
PolygonStyle(JSONObject json)
-
PolygonStyle
PolygonStyle(ScanbotColor strokeColor, ScanbotColor fillColor, Double strokeWidth, Double cornerRadius)
-
-
Method Detail
-
getStrokeColor
final ScanbotColor getStrokeColor()
The color of the polygon outline.
Default is "#FFFFFFFF"
-
setStrokeColor
final Unit setStrokeColor(ScanbotColor strokeColor)
The color of the polygon outline.
Default is "#FFFFFFFF"
-
getFillColor
final ScanbotColor getFillColor()
The fill color of the polygon.
Default is "#FFFFFF30"
-
setFillColor
final Unit setFillColor(ScanbotColor fillColor)
The fill color of the polygon.
Default is "#FFFFFF30"
-
getStrokeWidth
final Double getStrokeWidth()
The width of the polygon outline in dp.
Default is 2.0
-
setStrokeWidth
final Unit setStrokeWidth(Double strokeWidth)
The width of the polygon outline in dp.
Default is 2.0
-
getCornerRadius
final Double getCornerRadius()
The corner radius of the polygon in dp.
Default is 0.0
-
setCornerRadius
final Unit setCornerRadius(Double cornerRadius)
The corner radius of the polygon in dp.
Default is 0.0
-
toJson
final JSONObject toJson(ToJsonConfiguration config)
-
clone
final PolygonStyle clone()
-
default
final static PolygonStyle default()
-
-
-
-