0% found this document useful (0 votes)
21 views2 pages

Practical 10mad

The document is an XML layout for a login window in an Android application. It includes a title, two input fields for username and password, and a login button, all styled with specific attributes. The layout is designed to be user-friendly and visually appealing, with centered text and adequate padding.

Uploaded by

labadeshravani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views2 pages

Practical 10mad

The document is an XML layout for a login window in an Android application. It includes a title, two input fields for username and password, and a login button, all styled with specific attributes. The layout is designed to be user-friendly and visually appealing, with centered text and adequate padding.

Uploaded by

labadeshravani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

// Program to implement Login Window

<?xml version="1.0" encoding="utf-8"?>


<RelativeLayout xmlns:android="[Link]
xmlns:app="[Link]
xmlns:tools="[Link] android:id="@+id/main"
android:layout_width="match_parent"
android:layout_height="match_parent" tools:context=".MainActivity"
android:orientation="vertical"
android:padding="20dp">

<TextView android:id="@+id/tv1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Login"
android:layout_centerHorizontal="true"
android:textSize="40dp"
android:textStyle="bold" android:layout_marginTop="30dp"
android:textColor="#5E00FF"/>

<EditText android:id="@+id/et1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Username"
android:gravity="center"
android:inputType="text"
android:layout_below="@+id/tv1"
android:padding="20dp"
android:textSize="20dp"/>+

<EditText android:id="@+id/et2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Password" android:gravity="center"
android:inputType="text"
android:layout_below="@+id/et1"
android:padding="20dp"
android:textSize="20dp"/>

<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Login"
android:textSize="20dp"
android:textStyle="bold"
android:layout_below="@+id/et2"
android:layout_marginTop="30dp"/>
</RelativeLayout>

Output:

You might also like