Last active
September 19, 2024 01:50
-
-
Save CiTuX/5031751 to your computer and use it in GitHub Desktop.
Android xml drawable with a bottom stroke
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | |
<item | |
android:top="-6dp" | |
android:left="-6dp" | |
android:right="-6dp" | |
android:bottom="0dp"> | |
<shape android:shape="rectangle"> | |
<solid android:color="#88FFFF00"/> | |
<stroke | |
android:width="5dp" | |
android:color="#FF000000"/> | |
</shape> | |
</item> | |
</layer-list> |
shorter version
<?xml version="1.0" encoding="utf-8"?>
<inset xmlns:android="http://schemas.android.com/apk/res/android"
android:insetLeft="-6dp"
android:insetTop="-6dp"
android:insetRight="-6dp"
android:insetBottom="0dp">
<shape android:shape="rectangle">
<solid android:color="#88FFFF00" />
<stroke
android:width="5dp"
android:color="#FF000000" />
</shape>
</inset>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Works as intended. Thank you!