Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3.    xmlns:tools="http://schemas.android.com/tools"
  4.    android:layout_width="match_parent"
  5.    android:layout_height="match_parent"
  6.    android:padding="16dp"
  7.    android:orientation="vertical">
  8.  
  9.     <TextView
  10.        android:layout_width="match_parent"
  11.        android:layout_height="wrap_content"
  12.        android:text="Panjang" />
  13.     <EditText
  14.        android:id="@+id/edt_length"
  15.        android:layout_width="match_parent"
  16.        android:layout_height="wrap_content"
  17.        android:inputType="numberDecimal"
  18.        android:lines="1" />
  19.     <TextView
  20.        android:layout_width="match_parent"
  21.        android:layout_height="wrap_content"
  22.        android:text="Lebar" />
  23.     <EditText
  24.        android:id="@+id/edt_width"
  25.        android:layout_width="match_parent"
  26.        android:layout_height="wrap_content"
  27.        android:inputType="numberDecimal"
  28.        android:lines="1" />
  29.     <TextView
  30.        android:layout_width="match_parent"
  31.        android:layout_height="wrap_content"
  32.        android:text="Tinggi" />
  33.     <EditText
  34.        android:id="@+id/edt_height"
  35.        android:layout_width="match_parent"
  36.        android:layout_height="wrap_content"
  37.        android:inputType="numberDecimal"
  38.        android:lines="1" />
  39.     <Button
  40.        android:id="@+id/btn_calculate"
  41.        android:layout_width="match_parent"
  42.        android:layout_height="wrap_content"
  43.        android:text="Hitung" />
  44.     <TextView
  45.        android:id="@+id/tv_result"
  46.        android:layout_width="match_parent"
  47.        android:layout_height="wrap_content"
  48.        android:gravity="center"
  49.        android:text="Hasil"
  50.        android:textSize="24sp"
  51.        android:textStyle="bold" />
  52. </LinearLayout>