我想使用形状在Android中绘制水平和垂直虚线。
我想要绘制像这样的线条:
对于水平线:
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="line" >
<stroke
android:dashGap="6px"
android:dashWidth="6px"
android:color="#C7B299" />
</shape>
对于竖直线
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="line" >
<size
android:height="400dp"/>
<stroke
android:dashGap="6px"
android:dashWidth="6px"
android:color="#C7B299" />
</shape>
但是垂直虚线没有显示,我的输出结果就像这样:
如何绘制垂直线。