ParticlePainter constructor

ParticlePainter(
  1. Listenable? repaint, {
  2. required List<Particle> particles,
  3. bool paintEmitterTarget = true,
  4. Color emitterTargetColor = Colors.black,
})

Implementation

ParticlePainter(
  Listenable? repaint, {
  required this.particles,
  bool paintEmitterTarget = true,
  Color emitterTargetColor = Colors.black,
})  : _paintEmitterTarget = paintEmitterTarget,
      _emitterPaint = Paint()
        ..color = emitterTargetColor
        ..style = PaintingStyle.stroke
        ..strokeWidth = 2.0,
      _particlePaint = Paint()
        ..color = Colors.green
        ..style = PaintingStyle.fill,
      super(repaint: repaint);