用Python求Q函数的反函数 出现 Invalid limits given 错误,代码如下:
错误提示:
或者你可以编码:
int[] colors = {0, 0xFFFF0000, 0}; // red for the example
myList.setDivider(new GradientDrawable(Orientation.RIGHT_LEFT, colors));
myList.setDividerHeight(1);
希望能帮助到你
你可以使用一个布局xml文件来设置这个值android:divider="#FF0000"。如果您正在更改颜色/绘图,则必须设置/重置分隔线的高度。
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ListView
android:id="@+id/android:list"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:divider="#FFCC00"
android:dividerHeight="4px"/>
</LinearLayout>