UI基础入门-综合案例-02

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@mipmap/bg02"
    android:orientation="vertical"
    tools:context=".MainActivity">

    <TextView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginBottom="10dp"
        android:background="#B9B9ff"
        android:text="@string/start_select_food"
        android:textAlignment="center"
        android:textColor="#8A2B12"
        android:textSize="30sp"
        android:textStyle="bold|italic"
        android:typeface="monospace" />

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
        android:orientation="vertical">

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="45dp"
            android:layout_marginLeft="15dp"
            android:gravity="center_vertical"
            android:orientation="horizontal">

            <TextView
                android:layout_width="60dp"
                android:layout_height="wrap_content"
                android:text="@string/name"
                android:textSize="22sp" />

            <EditText
                android:id="@+id/nameEditText"
                android:layout_width="200dp"
                android:layout_height="wrap_content"
                android:hint="@string/edit_text_input_hint_name"
                />
        </LinearLayout>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="45dp"
            android:layout_marginLeft="15dp"
            android:gravity="center_vertical"
            android:orientation="horizontal">

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/sex"
                android:textSize="22sp" />

            <RadioGroup
                android:id="@+id/SexRadioGroup"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal">

                <RadioButton
                    android:id="@+id/maleRadioButton"
                    android:layout_width="75dp"
                    android:layout_height="wrap_content"
                    android:text="@string/male"
                    android:textSize="22sp"
                    />

                <RadioButton
                    android:id="@+id/femaleRadioButton"
                    android:layout_width="75dp"
                    android:layout_height="wrap_content"
                    android:text="@string/female"
                    android:textSize="22sp"
                    />
            </RadioGroup>
        </LinearLayout>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="45dp"
            android:layout_marginLeft="15dp"
            android:gravity="center_vertical"
            android:orientation="horizontal">

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/fond"
                android:textSize="22sp" />

            <LinearLayout
                android:id="@+id/Fond"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal">

                <CheckBox
                    android:id="@+id/hotCheckBox"
                    android:layout_width="65dp"
                    android:layout_height="wrap_content"
                    android:text="@string/hot"
                    android:textSize="22sp"
                    />

                <CheckBox
                    android:id="@+id/fishCheckBox"
                    android:layout_width="100dp"
                    android:layout_height="wrap_content"
                    android:text="@string/seafood"
                    android:textSize="22sp"
                    />

                <CheckBox
                    android:id="@+id/sourCheckBox"
                    android:layout_width="65dp"
                    android:layout_height="wrap_content"
                    android:text="@string/sour"
                    android:textSize="22sp"
                    />
            </LinearLayout>
        </LinearLayout>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="45dp"
            android:layout_marginLeft="15dp"
            android:gravity="center_vertical"
            android:orientation="horizontal">

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/budget"
                android:textSize="22sp" />

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

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:text="@string/_0yuan"
                    android:textSize="22sp" />

                <SeekBar
                    android:id="@+id/seekBar"
                    android:layout_width="210dp"
                    android:layout_height="wrap_content"
                    android:max="100"
                    android:textSize="22sp"/>

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:text="@string/_100yuan"
                    android:textSize="22sp" />
            </LinearLayout>
        </LinearLayout>

        <Button
            android:id="@+id/searchButton"
            android:layout_width="300dp"
            android:layout_height="50dp"
            android:gravity="center_horizontal"
            android:layout_gravity="center_horizontal"
            android:text="@string/search_food"
            android:textSize="22sp" />
    </LinearLayout>

    <!-- - - - - - - - - - 分界线 - - - - - - - - - - - - - -->

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
        android:orientation="vertical">

        <ImageView
            android:id="@+id/foodImageView"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:layout_weight="3"
            android:src="@mipmap/lock" />

        <ToggleButton
            android:id="@+id/showToggleButton"
            android:layout_width="300dp"
            android:layout_height="50dp"
            android:gravity="center_horizontal"
            android:layout_gravity="center_horizontal"
            android:textOff="@string/next_food"
            android:textOn="@string/details"
            android:textSize="22sp"/>
    </LinearLayout>


</LinearLayout>
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值