Skip to content

Commit

Permalink
using eraser size when in erasing mode
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-costaa committed Jul 26, 2024
1 parent c06bf32 commit c3517cb
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ class DrawingView @JvmOverloads constructor(
private fun createEraserPaint(): Paint {
val paint = createPaint()
paint.xfermode = PorterDuffXfermode(PorterDuff.Mode.CLEAR)
paint.strokeWidth = eraserSize
return paint
}

Expand Down Expand Up @@ -220,4 +221,4 @@ class DrawingView @JvmOverloads constructor(
visibility = GONE
currentShapeBuilder = ShapeBuilder()
}
}
}

0 comments on commit c3517cb

Please sign in to comment.