getStrokeStyle static method

Map<String, dynamic> getStrokeStyle([
  1. double width = 1,
  2. String color = '#000',
  3. String lineJoin = 'miter',
  4. String lineCap = 'butt',
  5. double miterLimit = 4,
])

Implementation

static Map<String,dynamic> getStrokeStyle([
  double width = 1,
  String color = '#000',
  String lineJoin = 'miter',
  String lineCap = 'butt',
  double miterLimit = 4
]) {
  // Param width: Stroke width
  // Param color: As returned by THREE.Color.getStyle()
  // Param lineJoin: One of "round", "bevel", "miter" or "miter-limit"
  // Param lineCap: One of "round", "square" or "butt"
  // Param miterLimit: Maximum join length, in multiples of the "width" parameter (join is truncated if it exceeds that distance)
  // Returns style object

  return {
    "strokeColor": color,
    "strokeWidth": width,
    "strokeLineJoin": lineJoin,
    "strokeLineCap": lineCap,
    "strokeMiterLimit": miterLimit
  };
}