Is it possible to use the `border()` modifier to j...
# compose
c
Is it possible to use the
border()
modifier to just draw on the bottom? Right now it's drawing a rectangle, but I'd love to tell it to just draw on bottom.
👀 1
v
Just tried defining custom shape, works fine:
Copy code
.border(
                width = 1.dp,
                color = myColor,
                shape = GenericShape { size, _ ->
                    moveTo(0f, size.height)
                    lineTo(size.width, size.height)
                }
            )
n
You should be able to use
Modifier.drawWithContent
API and call drawContent them drawLine which would be more efficient and avoid path operations
👍 3