Advertisement
ridjis

activity_main.xml -land

Dec 9th, 2015
331
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 6.48 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3.    xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent"
  4.    android:layout_height="match_parent" tools:context=".MainActivity">
  5.  
  6.  
  7.     <GridLayout
  8.        android:columnCount="5"
  9.        android:rowCount="4"
  10.        android:layout_marginTop="60dp"
  11.        android:layout_width="match_parent"
  12.        android:layout_height="match_parent"
  13.        android:layout_alignParentTop="true"
  14.        android:layout_alignParentLeft="true"
  15.        android:layout_alignParentStart="true">
  16.  
  17.         <Button
  18.            android:layout_columnWeight="1"
  19.            android:layout_rowWeight="1"
  20.            android:layout_rowSpan="2"
  21.            android:layout_width="wrap_content"
  22.            android:layout_height="wrap_content"
  23.            android:text="C"
  24.            android:id="@+id/clear"
  25.            android:layout_row="0"
  26.            android:layout_column="4" />
  27.  
  28.         <Button
  29.            android:layout_columnWeight="1"
  30.            android:layout_rowWeight="1"
  31.            android:layout_rowSpan="2"
  32.            android:layout_width="wrap_content"
  33.            android:layout_height="wrap_content"
  34.            android:text="="
  35.            android:id="@+id/jednako"
  36.            android:layout_row="2"
  37.            android:layout_column="4" />
  38.  
  39.         <Button
  40.            android:layout_rowWeight="1"
  41.            android:layout_columnWeight="1"
  42.            android:layout_width="wrap_content"
  43.            android:layout_height="wrap_content"
  44.            android:text="1"
  45.            android:layout_row="0"
  46.            android:layout_column="0"
  47.            android:id="@+id/jedan" />
  48.         <Button
  49.            android:layout_rowWeight="1"
  50.            android:layout_columnWeight="1"
  51.            android:layout_width="wrap_content"
  52.            android:layout_height="wrap_content"
  53.            android:text="2"
  54.            android:layout_row="0"
  55.            android:layout_column="1"
  56.            android:id="@+id/dva" />
  57.         <Button
  58.            android:layout_rowWeight="1"
  59.            android:layout_columnWeight="1"
  60.            android:layout_width="wrap_content"
  61.            android:layout_height="wrap_content"
  62.            android:text="3"
  63.            android:layout_row="0"
  64.            android:layout_column="2"
  65.            android:id="@+id/tri" />
  66.         <Button
  67.            android:layout_rowWeight="1"
  68.            android:layout_columnWeight="1"
  69.            android:layout_width="wrap_content"
  70.            android:layout_height="wrap_content"
  71.            android:text="+"
  72.            android:layout_row="0"
  73.            android:layout_column="3"
  74.            android:id="@+id/plus" />
  75.         <Button
  76.            android:layout_rowWeight="1"
  77.            android:layout_columnWeight="1"
  78.            android:layout_width="wrap_content"
  79.            android:layout_height="wrap_content"
  80.            android:text="4"
  81.            android:layout_row="1"
  82.            android:layout_column="0"
  83.            android:id="@+id/cetiri" />
  84.         <Button
  85.            android:layout_rowWeight="1"
  86.            android:layout_columnWeight="1"
  87.            android:layout_width="wrap_content"
  88.            android:layout_height="wrap_content"
  89.            android:text="5"
  90.            android:layout_row="1"
  91.            android:layout_column="1"
  92.            android:id="@+id/pet" />
  93.         <Button
  94.            android:layout_rowWeight="1"
  95.            android:layout_columnWeight="1"
  96.            android:layout_width="wrap_content"
  97.            android:layout_height="wrap_content"
  98.            android:text="6"
  99.            android:layout_row="1"
  100.            android:layout_column="2"
  101.            android:id="@+id/sest" />
  102.         <Button
  103.            android:layout_rowWeight="1"
  104.            android:layout_columnWeight="1"
  105.            android:layout_width="wrap_content"
  106.            android:layout_height="wrap_content"
  107.            android:text="-"
  108.            android:layout_row="1"
  109.            android:layout_column="3"
  110.            android:id="@+id/minus" />
  111.         <Button
  112.            android:layout_rowWeight="1"
  113.            android:layout_columnWeight="1"
  114.            android:layout_width="wrap_content"
  115.            android:layout_height="wrap_content"
  116.            android:text="7"
  117.            android:layout_row="2"
  118.            android:layout_column="0"
  119.            android:id="@+id/sedam" />
  120.         <Button
  121.            android:layout_rowWeight="1"
  122.            android:layout_columnWeight="1"
  123.            android:layout_width="wrap_content"
  124.            android:layout_height="wrap_content"
  125.            android:text="8"
  126.            android:layout_row="2"
  127.            android:layout_column="1"
  128.            android:id="@+id/osam" />
  129.         <Button
  130.            android:layout_rowWeight="1"
  131.            android:layout_columnWeight="1"
  132.            android:layout_width="wrap_content"
  133.            android:layout_height="wrap_content"
  134.            android:text="9"
  135.            android:layout_row="2"
  136.            android:layout_column="2"
  137.            android:id="@+id/devet" />
  138.         <Button
  139.            android:layout_rowWeight="1"
  140.            android:layout_columnWeight="1"
  141.            android:layout_width="wrap_content"
  142.            android:layout_height="wrap_content"
  143.            android:text="*"
  144.            android:layout_row="2"
  145.            android:layout_column="3"
  146.            android:id="@+id/puta" />
  147.         <Button
  148.            android:layout_rowWeight="1"
  149.            android:layout_columnWeight="1"
  150.            android:layout_width="wrap_content"
  151.            android:layout_height="wrap_content"
  152.            android:text="0"
  153.            android:layout_row="3"
  154.            android:layout_column="1"
  155.            android:id="@+id/nula" />
  156.         <Button
  157.            android:layout_rowWeight="1"
  158.            android:layout_columnWeight="1"
  159.            android:layout_width="wrap_content"
  160.            android:layout_height="wrap_content"
  161.            android:text="/"
  162.            android:layout_row="3"
  163.            android:layout_column="3"
  164.            android:id="@+id/podijeljeno" />
  165.     </GridLayout>
  166.  
  167.     <EditText
  168.        android:layout_width="match_parent"
  169.        android:layout_height="50dp"
  170.        android:id="@+id/editText"
  171.        android:textSize="20sp"
  172.        android:layout_alignParentTop="true"
  173.        android:layout_alignParentLeft="true"
  174.        android:layout_alignParentStart="true" />
  175. </RelativeLayout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement