Skip to content

Instantly share code, notes, and snippets.

@zurche
Created July 27, 2023 11:12
Show Gist options
  • Save zurche/e953942bcdff9fcbd7baaba65d24e95c to your computer and use it in GitHub Desktop.
Save zurche/e953942bcdff9fcbd7baaba65d24e95c to your computer and use it in GitHub Desktop.
private fun DrawScope.drawCurvyLine() {
val stroke = Path().apply {
moveTo(size.width.times(.9f), size.height.times(0f))
quadraticBezierTo(
size.width.times(.9f), size.height.times(.28f),
size.width.times(.73f), size.height.times(.15f)
)
quadraticBezierTo(
size.width.times(.53f), size.height.times(0f),
size.width.times(.55f), size.height.times(.25f)
)
}
drawPath(
stroke,
color = CryptoOrange4,
style = Stroke(
width = 50f,
cap = StrokeCap.Round
)
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment