由于经常写一些listview布局 要求不高 就随便着了个布局来实现 用了CardView 这个控件 方便之处在于 自带卡片状阴影 缺点就是两边不能最大到无边框 就是一个卡片形状 偷懒用的 还是导入工具类 compile 'com.android.support:cardview-v7:25.0.1' 在布局中使用 <android.support.v7.widget.CardView android:id="@+id/ll_noclick" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginLeft="@dimen/x20" android:layout_marginRight="@dimen/x20" android:background="@color/hui" android:orientation="vertical" app:cardPreventCornerOverlap="true" app:cardUseCompatPadding="true"> 上个图 大概样式
|