如何在forml中为xml制作这样的drawable? 我正在考虑使用图层列表,但它似乎不起作用:
这是我现在所拥有的:
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item>
<rotate
android:fromDegrees="45"
android:toDegrees="45"
android:pivotX="0%"
android:pivotY="100%" >
<shape
android:shape="rectangle" >
<stroke android:color="@android:color/transparent" android:width="10dp"/>
<solid
android:color="@color/colorPrimary" />
</shape>
</rotate>
</item>
<item>
<rotate
android:fromDegrees="-45"
android:toDegrees="45"
android:pivotX="0%"
android:pivotY="0%" >
<shape
android:shape="rectangle" >
<stroke android:color="@android:color/transparent" android:width="10dp"/>
<solid
android:color="@color/colorPrimary" />
</shape>
</rotate>
</item>
<item>
<shape
android:shape="rectangle" >
<stroke android:color="@android:color/transparent" android:width="10dp"/>
<solid
android:color="@color/colorPrimary" />
</shape>
</item>
</layer-list>
这就是我需要的:
如何实现这样的目标呢? 或者是否有这种形状的在线生成器?