home_test_top_item_view.xml 4.32 KB
Newer Older
徐健 committed
1 2 3 4 5 6 7 8
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
                xmlns:app="http://schemas.android.com/apk/res-auto"
                xmlns:tools="http://schemas.android.com/tools"
                android:layout_width="match_parent"
                android:layout_height="match_parent">


YKai committed
9
    <androidx.cardview.widget.CardView
徐健 committed
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
        android:id="@+id/homeModuleIntelligentTopViewImageCardView"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        app:cardCornerRadius="@dimen/platform_dp_7"
        app:cardElevation="0dp">

        <RelativeLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent">

            <ImageView
                android:id="@+id/homeModuleIntelligentTopViewImage"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:background="@drawable/home_image_default_back"
                android:scaleType="centerCrop"/>

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:orientation="vertical">

                <View
                    android:layout_width="match_parent"
                    android:layout_height="0dp"
                    android:layout_weight="45"/>

                <View
                    android:layout_width="match_parent"
                    android:layout_height="0dp"
                    android:layout_weight="55"
                    android:background="@drawable/home_intelligent_gradient_back"/>
            </LinearLayout>

        </RelativeLayout>
YKai committed
45
    </androidx.cardview.widget.CardView>
徐健 committed
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107


    <TextView
        android:id="@+id/homeModuleIntelligentTopViewTitle"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentLeft="true"
        android:layout_alignParentBottom="true"
        android:layout_marginLeft="@dimen/platform_dp_14"
        android:layout_marginRight="@dimen/platform_dp_115"
        android:layout_marginBottom="67dp"
        android:ellipsize="end"
        android:maxLines="1"
        android:textColor="@color/platform_color_FFFFFF"
        android:textSize="@dimen/platform_dp_24"
        android:textStyle="bold"
        tools:text="先结婚还是先买先结婚还是先买房"
        />

    <LinearLayout
        android:id="@+id/homeModuleIntelligentTopViewDescLayout"
        android:layout_width="wrap_content"
        android:layout_height="@dimen/platform_dp_18"
        android:layout_alignLeft="@+id/homeModuleIntelligentTopViewTitle"
        android:layout_alignParentBottom="true"
        android:layout_marginBottom="43dp"
        android:background="@drawable/home_test_top_view_layout_back"
        android:gravity="center_vertical"
        android:orientation="horizontal"
        android:paddingLeft="@dimen/platform_dp_10"
        android:paddingRight="@dimen/platform_dp_10">

        <TextView
            android:id="@+id/homeModuleIntelligentTopViewHits"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:textColor="@color/platform_color_444444"
            android:textSize="@dimen/platform_dp_12"
            android:textStyle="bold"
            tools:text="2486"
            />

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="已测"
            android:textColor="@color/platform_color_666666"
            android:textSize="@dimen/platform_dp_12"
            />
    </LinearLayout>

    <RelativeLayout
        android:layout_width="@dimen/platform_dp_64"
        android:layout_height="@dimen/platform_dp_20"
        android:layout_alignParentRight="true"
        android:background="@drawable/home_intelligent_top_view_recommend_back">

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_centerInParent="true"
            android:text="每日一测"
konghaorui committed
108
            android:textColor="@color/platform_but_text_color_specific"
徐健 committed
109 110 111 112 113
            android:textSize="@dimen/platform_dp_12"
            android:textStyle="bold"/>
    </RelativeLayout>

</RelativeLayout>