private static Paint getNewPaintOrNull(float thickness, int color) {
    if (thickness > 0) {
      Paint borderPaint = new Paint();
      borderPaint.setColor(color);
      borderPaint.setStrokeWidth(thickness);
      borderPaint.setStyle(Paint.Style.STROKE);
      borderPaint.setAntiAlias(true);
      return borderPaint;
    } else {
      return null;
    }
  }
Creates the Paint object for given thickness and color, if thickness < 0 return null.
core/src/main/java/com/theartofdev/edmodo/cropper/CropOverlayView.java