【问题标题】:Drawable shape with arrow in the middle of the shape border形状边框中间带有箭头的可绘制形状
【发布时间】:2018-09-05 09:43:50
【问题描述】:

我怎样才能让一个可绘制的文件拥有像这张图片一样的视图?

【问题讨论】:

标签: android android-layout drawable shapes


【解决方案1】:

这里是drawabe图片的解决方案

 <?xml version="1.0" encoding="utf-8"?>
    <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
        <item>
            <shape android:shape="rectangle">
                <solid android:color= "@color/themeColor"></solid>
                <size android:width="150dp" android:height="100dp"/>
            </shape>
        </item>
        <item>
            <rotate android:fromDegrees="45" android:toDegrees="45"
                android:pivotX="12%" android:pivotY="-140%" >
                <shape android:shape="rectangle" >
                    <solid android:color="#ffffff" />
                </shape>
            </rotate>
        </item>
    </layer-list>

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-06-29
    • 1970-01-01
    • 2016-11-03
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多