Newer
Older
Meterage / app / src / main / res / layout / fragment_mine.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/rootView"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/mainBackground"
    android:orientation="vertical">

    <androidx.core.widget.NestedScrollView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:scrollbars="none">

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

            <!--用户信息Layout-->
            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="@dimen/dp_150"
                android:background="@mipmap/mine_top"
                android:orientation="vertical">

                <View
                    android:id="@+id/statusBarView"
                    android:layout_width="match_parent"
                    android:layout_height="0dp"
                    android:background="#00000000" />

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

                    <ImageView
                        android:id="@+id/userAvatarView"
                        android:layout_width="80dp"
                        android:layout_height="80dp"
                        android:layout_gravity="center_vertical"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:src="@mipmap/default_avatar" />

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_gravity="center_vertical"
                        android:layout_marginEnd="@dimen/dp_15"
                        android:orientation="vertical">

                        <RelativeLayout
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:layout_marginBottom="@dimen/dp_7">

                            <TextView
                                android:id="@+id/userNameView"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="刘俊凯"
                                android:textColor="@color/white"
                                android:textSize="@dimen/sp_22" />

                            <FrameLayout
                                android:id="@+id/noticeLayout"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_alignParentEnd="true">

                                <ImageView
                                    android:layout_width="@dimen/pngSize"
                                    android:layout_height="@dimen/pngSize"
                                    android:src="@mipmap/message_white" />

                                <TextView
                                    android:id="@+id/noticeCountView"
                                    android:layout_width="@dimen/dp_15"
                                    android:layout_height="@dimen/dp_15"
                                    android:layout_gravity="end"
                                    android:background="@drawable/bg_text_view_red_radius_10"
                                    android:gravity="center"
                                    android:text="9+"
                                    android:textColor="@color/white"
                                    android:textSize="@dimen/sp_10" />
                            </FrameLayout>
                        </RelativeLayout>

                        <TextView
                            android:id="@+id/userUnitView"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_marginTop="@dimen/dp_7"
                            android:singleLine="true"
                            android:text="北京达佳科技有限公司"
                            android:textColor="@color/white"
                            android:textSize="@dimen/sp_18" />
                    </LinearLayout>
                </LinearLayout>
            </LinearLayout>

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:orientation="vertical"
                android:padding="@dimen/dp_15">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:background="@drawable/bg_solid_layout_white_radius_10"
                    android:orientation="vertical">

                    <RelativeLayout
                        android:id="@+id/userAccountLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/account" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="账户信息" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>

                    <View
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/dividerLine"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:background="@color/mainBackground" />

                    <RelativeLayout
                        android:id="@+id/userCollectionLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/collection" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="我的收藏" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>
                </LinearLayout>

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="@dimen/dp_15"
                    android:background="@drawable/bg_solid_layout_white_radius_10"
                    android:orientation="vertical">

                    <RelativeLayout
                        android:id="@+id/pushSettingLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/push_setting" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="推送设置" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>

                    <View
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/dividerLine"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:background="@color/mainBackground" />

                    <RelativeLayout
                        android:id="@+id/privacyLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/privacy" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="隐私设置" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>
                </LinearLayout>

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="@dimen/dp_15"
                    android:background="@drawable/bg_solid_layout_white_radius_10"
                    android:orientation="vertical">

                    <RelativeLayout
                        android:id="@+id/helpLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/help" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="使用帮助" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>

                    <View
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/dividerLine"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:background="@color/mainBackground" />

                    <RelativeLayout
                        android:id="@+id/updateLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/update" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="版本更新" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>

                    <View
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/dividerLine"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:background="@color/mainBackground" />

                    <RelativeLayout
                        android:id="@+id/aboutLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/about" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="关于APP" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>

                    <View
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/dividerLine"
                        android:layout_marginHorizontal="@dimen/dp_15"
                        android:background="@color/mainBackground" />

                    <RelativeLayout
                        android:id="@+id/backLayout"
                        style="@style/itemLayoutStyle">

                        <ImageView
                            style="@style/leftImageStyle"
                            android:background="@mipmap/back" />

                        <TextView
                            style="@style/mainFragmentTextStyle"
                            android:text="意见反馈" />

                        <ImageView style="@style/rightImageStyle" />
                    </RelativeLayout>
                </LinearLayout>
            </LinearLayout>
        </LinearLayout>
    </androidx.core.widget.NestedScrollView>
</LinearLayout>