【发布时间】:2017-09-03 14:18:35
【问题描述】:
我想设置圆圈大小,但我不想调整图层列表中其他元素的大小。 我有这个代码:
<?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/drawer_color" />
</shape>
</item>
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="oval">
<gradient
android:endColor="#1b2727"
android:centerColor="#1a2a29"
android:startColor="#154440"
android:type="linear"
android:angle="90"/>
<size
android:height="600dp"
android:width="600dp" />
<stroke
android:width="3dip"
android:color="@color/drawer_ring_color" />
</shape>
</item>
</layer-list>
如何做到这一点? 谢谢!
【问题讨论】:
标签: android xml user-interface shape