KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I want to set the background of a Relative or LinearLayout to a custom drawable. I want the shape to draw two horizontal lines across the bottom, leaving the central part transparent (empty). The following draws the horizontal lines centered vertically, where as I need them to be aligned to the bottom of the shape. (If you add a rectangle as an item you can see the shape expands to the dimenstions of the parent, but the lines are still centrally aligned). <?xml version="1.0" encoding="utf-8"?> <layer-list xmlns:android="http://schemas.android.com/apk/res/android" > <item> <shape android:shape="line"> <stroke android:width="1dip" android:color="#99b8b9bd" /> <size android:height="1dip" /> </shape> </item> <item> <shape android:shape="line" android:top="1dip"> <stroke android:width="1dip" android:color="#FFFFFFFF" /> <size android:height="1dip" /> </shape> </item> </layer-list>
Tags (comma-separated)
Save Edits
Cancel