小编Rau*_*rma的帖子

如何在recyclerview项目之间设置相等的保证金

这个图片

看到这张图片

我从xml布局中获得了当前的余量,但是在所有四个方面都不一样.

如何获得相等的保证金

我目前的xml布局

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="300dp">

<ImageView
    android:id="@+id/iv_photo"
    android:layout_width="match_parent"
    android:layout_height="300dp"
    android:layout_marginEnd="6dp"
    android:layout_marginTop="6dp"
    android:adjustViewBounds="true"
    android:background="@color/colorPrimary"
    android:foreground="?android:attr/selectableItemBackground"
    android:scaleType="fitXY" />

</RelativeLayout>
Run Code Online (Sandbox Code Playgroud)

android android-recyclerview

5
推荐指数
2
解决办法
2949
查看次数

标签 统计

android ×1

android-recyclerview ×1