I am trying to make a view in android with rounded edges. The solution I found so far is to define a shape with rounded corners and use it as the background of that view.
You can use an androidx.cardview.widget.CardView like so:
androidx.cardview.widget.CardView
...
OR
shape.xml
and inside you layout