<shape
xmlns:android=" CodeGo.net
android:shape="rectangle"
android:height="60px"
>
<shape
android:shape="rectangle"
android:height="30px"
>
<solid
android:color="#ff297baf"
/>
</shape>
<shape
android:shape="rectangle"
android:height="30px"
>
<gradient
android:type="linear"
android:startColor="#ff297baf"
android:endColor="#ff16c0e3"
android:angle="270"/>
</shape>
<shape
android:shape="rectangle"
android:height="3px"
>
<solid
android:color="#FFFFFFFF"
/>
</shape>
</shape>
xmlns:android=" CodeGo.net
android:shape="rectangle"
android:height="60px"
>
<shape
android:shape="rectangle"
android:height="30px"
>
<solid
android:color="#ff297baf"
/>
</shape>
<shape
android:shape="rectangle"
android:height="30px"
>
<gradient
android:type="linear"
android:startColor="#ff297baf"
android:endColor="#ff16c0e3"
android:angle="270"/>
</shape>
<shape
android:shape="rectangle"
android:height="3px"
>
<solid
android:color="#FFFFFFFF"
/>
</shape>
</shape>
解决方案 »
- 如何使LinearLayout自动填充剩余空间??
- OTA升级包update.zip中的update-binary有什么作用
- android如何支持svg?
- 长按按键执行某个APK如何实现?
- (很多人都提过的这个问题)android一样的代码,却不能正常运行
- Android Studio 新建文件时出现的问题
- 这种listview怎么实现
- 开发Android平板应用程序过程中被困扰了很多天的问题!求大神支招
- 提示Error log错误,无法运行
- 使用友推分享sdk时遇到一些问题,求大神帮忙
- 请问电脑上如何设计Android的布局大小
- 在 getview 中 有查询数据库 操作 会产生 什么 后果?
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" > <item>
<shape>
<solid android:color="#FFFFFFFF" /> <stroke
android:width="3dp"
android:color="#228B22" /> <corners android:radius="2dp" /> <padding
android:bottom="8dp"
android:left="8dp"
android:right="8dp"
android:top="8dp" />
</shape>
</item>
<item>
<shape>
<solid android:color="#FFFFFFFF" /> <stroke
android:width="3dp"
android:color="#228B22" /> <corners android:radius="2dp" /> <padding
android:bottom="2dp"
android:left="2dp"
android:right="2dp"
android:top="2dp" />
</shape>
</item></layer-list>PS:不建议这么做,最好是用张图片。
按照你给出的样式,效果如下:
按照你给出的样式,单独预览效果时如下:程序在虚拟机中运行效果如下: