Anyone have an idea how I can achieve this backgro...
# android
j
Anyone have an idea how I can achieve this background for an EditText using a drawable XML file? Wondering if it's possible at all. There should be a 4dp corner radius and a bottom stroke that is 2dp thick.
stackoverflow 3
K 2
google 2
r
You can use a 'trimmed' shape on top of the EditText.
j
it is just a, for example,
MaterialCardView
, corners to 4dp and a view inside aligned to the bottom with a height of 2dp
j
I would like to find a solution where I am able to just style the EditText component - if that's possible at all. Thanks for the other suggestions ­čÖé
u
You can use layerlist and place item overlay and this can be easily achieve
j
Easily is a dangerous term. Do you have an example of how this explicit problem can be solved using layer-list? I have tried every possible solution I can think of.
u
Is this view matches your requirement
I developed using layer-list
@jaran
j
This is not the same, as your "bottom border" covers the entire rounded corner. I need a bottom border which only corvers half the rounded corner - which is the difficult part here.
But thanks for the suggestion.
u
That can be like inputs of values in drawable
I used 5