activity_main.xml 2.8 KB
Newer Older
C
channings 已提交
1 2 3 4 5 6 7 8 9 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 45 46 47 48 49 50 51 52 53 54 55 56 57 58
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout 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="fill_parent"
                                             android:layout_height="fill_parent"
                                             tools:context=".MainActivity">

    <ScrollView
            android:layout_width="fill_parent"
            android:layout_height="fill_parent"
            android:fadingEdge="vertical"
            android:scrollbars="vertical">
        <LinearLayout
                android:layout_width="fill_parent"
                android:layout_height="fill_parent"
                android:orientation="vertical">

            <LinearLayout
                    android:layout_width="fill_parent"
                    android:layout_height="300dp"
                    android:orientation="horizontal">
                <RelativeLayout
                        android:id="@+id/v_img_seg"
                        android:layout_width="wrap_content"
                        android:layout_height="fill_parent"
                        android:layout_weight="1"
                        android:clickable="true"
                        android:onClick="onClick">

                    <ImageView
                            android:id="@+id/iv_img_seg_image"
                            android:layout_width="200dp"
                            android:layout_height="200dp"
                            android:layout_centerHorizontal="true"
                            android:layout_centerVertical="true"
                            android:layout_margin="12dp"
                            android:adjustViewBounds="true"
                            android:src="@drawable/image_segementation"
                            android:scaleType="fitCenter"/>

                    <TextView
                            android:id="@+id/iv_img_seg_title"
                            android:layout_below="@id/iv_img_seg_image"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_centerHorizontal="true"
                            android:layout_margin="8dp"
                            android:text="Image Segmentation"
                            android:textStyle="bold"
                            android:textAllCaps="false"
                            android:singleLine="false"/>
                </RelativeLayout>

            </LinearLayout>
        </LinearLayout>
    </ScrollView>
</android.support.constraint.ConstraintLayout>