fromJson static method
Implementation
static HorizontalRayTool fromJson(Map<String, dynamic> json) {
return HorizontalRayTool(
id: json['id'],
startPoint: json['startPoint'] != null
? Offset(json['startPoint']['x'], json['startPoint']['y'])
: null,
direction: json['direction'],
color: Color(json['color']),
strokeWidth: json['strokeWidth'],
);
}