Desarrollo de software móvil Lección 5 - La primera aplicación de Android

Informe de laboratorio "Desarrollo de software móvil" del verano de 2022

Nombre: xxx alumno número 2002000xxxx

¿Nombre y número de estudiante?        

xxx2002000xxxx

¿A qué curso pertenece este laboratorio?

Ocean University of China 22 Verano "Desarrollo de software móvil"

¿Nombre del experimento?          

Experimento 5: La primera aplicación de Android

¿Dirección del blog?          

¿Dirección del almacén de Github?

1. Objetivos experimentales,

Imite la página de "descubrimiento" de WeChat para crear un diseño de lista, aprenda a usar Textview imageview, LinearLayout

En segundo lugar, los pasos experimentales.

1, creación de proyectos

2, configuración de página

 

 

3, ver diseño

 

4, implementación lógica

 

En tercer lugar, el programa que ejecuta los resultados

 

Código general:

<?versión xml="1.0" codificación="utf-8"?>
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:background ="#e5e5e5"
    android:layout_height="match_parent"
    android:orientation="vertical"
    >

    <LinearLayout
        android:layout_marginTop="15dp"
        android:layout_width="match_parent"
        android:layout_height="60dp"
        android:background="#fff "
        android:orientación="horizontal">

        <ImageView
            android:layout_width="40dp"
            android:layout_height="40dp"
            android:layout_gravity="center_vertical"
            android:layout_marginLeft="15dp"
            android:background="@mipmap/icon_pengyou" />
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:layout_marginLeft="10dp"
            android:layout_weight="1"
            android :gravity="center_vertical"
            android:text="朋友圈"
            android:textColor="#333"
            android:textSize="18dp"
            android:textStyle="bold" />

        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical"
            android:layout_marginRight="15dp"
            android:background="@mipmap/right" />
    </LinearLayout>

    <LinearLayout
        android:layout_marginTop="30dp"
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width ="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/mano2"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="扫一扫"
            android:layout_marginLeft="10dp"
            android:textStyle="negrita"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity=" center_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right "/>
    </LinearLayout>

    <LinearLayout
        android:fondo="#fff"
        android:orientación="horizontal"
        android:layout_width="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity= "center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/shake3"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="摇一摇"
            android:layout_marginLeft="10dp"
            android:textStyle="negrita"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity="center_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight ="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right"/>
    </LinearLayout>

    <LinearLayout
        android:layout_marginTop="30dp"
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/eye4"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="看一看"
            android:layout_marginLeft="10dp"
            android:textStyle="negrita"
            android:textColor="#333"
            android:textSize ="18dp"
            android:gravedad="centro_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right"/ >
    </LinearLayout>

    <LinearLayout
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/search5"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="搜一搜"
            android:layout_marginLeft="10dp "
            android:textStyle="bold"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity="center_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right"/>
    </LinearLayout>

    <LinearLayout
        android:layout_marginTop="30dp"
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width ="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/game7"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="游戏"
            android:layout_marginLeft="10dp"
            android:textStyle="bold"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity="center_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right"/>
    </LinearLayout>

    <LinearLayout
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height=" 40dp"
            android:background="@mipmap/shopping6"/>
        <TextView
            android:layout_width="0dp"
            android:layout_height="match_parent"
            android:text="购物"
            android:layout_marginLeft="10dp"
            android:textStyle="negrita"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity="center_vertical"
            android:layout_weight="1"/>
        <ImageView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity= "center_vertical"
            android:background="@mipmap/right"/>
    </LinearLayout>

    <LinearLayout
        android:layout_marginTop="30dp"
        android:background="#fff"
        android:orientation="horizontal"
        android:layout_width="match_parent"
        android:layout_height="60dp">
        <ImageView
            android:layout_width="40dp"
            android:layout_marginLeft="15dp"
            android:layout_gravity="center_vertical"
            android:layout_height="40dp"
            android:background="@mipmap/prog8"/>
        <TextView
            android:layout_width="0dp"
            android :layout_height="match_parent"
            android:text="小程序"
            android:layout_marginLeft="10dp"
            android:textStyle="negrita"
            android:textColor="#333"
            android:textSize="18dp"
            android:gravity="center_vertical"
            android:layout_weight="1"/>
        <Vista de imagen
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginRight="15dp"
            android:layout_gravity="center_vertical"
            android:background="@mipmap/right"/>
    </LinearLayout>

</LinearLayout>

Cuarto, resumen del problema y experiencia.

    Esta clase me ha beneficiado mucho y he aprendido a crear diseños. También me enseñó a usar los componentes de manera flexible.

Supongo que te gusta

Origin blog.csdn.net/m0_55933489/article/details/126528963
Recomendado
Clasificación