<?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="wrap_content" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:paddingLeft="16dp" android:paddingRight="16dp" android:paddingTop="4dp"> <androidx.cardview.widget.CardView android:id="@+id/homeModuleArticleItemViewCardImg" android:layout_width="88dp" android:layout_height="70dp" android:layout_alignParentRight="true" app:cardCornerRadius="8dp" app:cardElevation="0dp"> <ImageView android:layout_width="match_parent" android:layout_height="match_parent" android:scaleType="centerCrop" android:id="@+id/homeModuleArticleItemViewImg" tools:src="@drawable/home_image_default_back"/> </androidx.cardview.widget.CardView> <TextView android:id="@+id/homeModuleArticleItemViewTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxHeight="44dp" android:maxLines="2" android:ellipsize="end" android:textSize="16sp" android:textStyle="bold" android:textColor="#1C1F28" android:lineSpacingExtra="@dimen/platform_dp_1" tools:text="喧嚣的世界中,你的重要何以而来?" android:layout_alignParentLeft="true" android:layout_alignTop="@id/homeModuleArticleItemViewCardImg" android:layout_toLeftOf="@+id/homeModuleArticleItemViewCardImg" android:layout_marginRight="18dp"/> <TextView android:id="@+id/homeModuleArticleItemViewContent" android:layout_width="wrap_content" android:layout_height="18dp" android:layout_marginTop="8dp" android:maxLines="1" android:gravity="center_vertical" android:ellipsize="end" android:textSize="@dimen/platform_dp_13" android:textColor="#9D9EA7" android:layout_alignParentLeft="true" tools:text="喧嚣的世界中,你的重要何以而来?当我伫立在我所伫立之处..." android:layout_toLeftOf="@+id/homeModuleArticleItemViewCardImg" android:layout_below="@id/homeModuleArticleItemViewTitle" android:layout_marginRight="18dp"/> <androidx.constraintlayout.widget.ConstraintLayout android:id="@+id/homeModuleArticleItemViewBottomLayout" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_below="@+id/homeModuleArticleItemViewCardImg" android:layout_marginTop="17dp"> <androidx.cardview.widget.CardView android:id="@+id/card_view_avatar" android:layout_width="16dp" android:layout_height="16dp" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" app:layout_constraintBottom_toBottomOf="parent" app:cardElevation="0dp" app:cardCornerRadius="8dp"> <ImageView android:id="@+id/homeModuleArticleItemViewIcon" android:layout_width="16dp" android:layout_height="16dp" android:src="@drawable/home_article_item_icon"/> </androidx.cardview.widget.CardView> <TextView android:id="@+id/homeModuleArticleItemViewAuthor" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="13sp" android:textColor="#62636F" android:layout_marginLeft="5dp" app:layout_constraintStart_toEndOf="@id/card_view_avatar" app:layout_constraintTop_toTopOf="parent" app:layout_constraintBottom_toBottomOf="parent" tools:text="赵秀英"/> <TextView android:id="@+id/homeModuleArticleItemViewLookNum" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="70dp" tools:text="2656浏览" android:textSize="13sp" android:textColor="#62636F" app:layout_constraintTop_toTopOf="parent" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent"/> <TextView android:id="@+id/homeModuleArticleItemViewGreatNum" android:layout_width="wrap_content" android:layout_height="wrap_content" tools:text="3327点赞" android:textSize="13sp" android:textColor="#62636F" app:layout_constraintTop_toTopOf="parent" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent"/> </androidx.constraintlayout.widget.ConstraintLayout> <View android:id="@+id/homeModuleArticleItemViewBottomLine" android:layout_width="match_parent" android:layout_height="0.5dp" android:background="#EFEFF1" android:layout_centerInParent="true" android:layout_below="@+id/homeModuleArticleItemViewBottomLayout" android:layout_marginTop="20dp" android:layout_marginBottom="30dp"/> </RelativeLayout>