Advertisement
Guest User

Untitled

a guest
Sep 23rd, 2019
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.18 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:app="http://schemas.android.com/apk/res-auto"
  4. xmlns:tools="http://schemas.android.com/tools"
  5. android:layout_width="match_parent"
  6. android:layout_height="match_parent"
  7. tools:context=".Calculatrice">
  8.  
  9. <TableLayout
  10. android:layout_width="395dp"
  11. android:layout_height="198dp"
  12. android:layout_marginStart="8dp"
  13. android:layout_marginTop="8dp"
  14. android:layout_marginEnd="8dp"
  15. android:layout_marginBottom="8dp"
  16. android:shrinkColumns="*"
  17. android:stretchColumns="*"
  18. app:layout_constraintBottom_toBottomOf="parent"
  19. app:layout_constraintEnd_toEndOf="parent"
  20. app:layout_constraintStart_toStartOf="parent"
  21. app:layout_constraintTop_toTopOf="parent">
  22.  
  23. <TableRow
  24. android:layout_width="match_parent"
  25. android:layout_height="match_parent">
  26.  
  27. <Button
  28. android:id="@+id/button2"
  29. android:layout_width="wrap_content"
  30. android:layout_height="wrap_content"
  31. android:onClick="clicButton"
  32. android:text="7" />
  33.  
  34. <Button
  35. android:id="@+id/button3"
  36. android:layout_width="wrap_content"
  37. android:layout_height="wrap_content"
  38. android:onClick="clicButton"
  39. android:text="8" />
  40.  
  41. <Button
  42. android:id="@+id/button4"
  43. android:layout_width="wrap_content"
  44. android:layout_height="wrap_content"
  45. android:onClick="clicButton"
  46. android:text="9" />
  47.  
  48. <Button
  49. android:id="@+id/button5"
  50. android:layout_width="wrap_content"
  51. android:layout_height="wrap_content"
  52. android:backgroundTint="@android:color/holo_green_light"
  53. android:onClick="clicButton"
  54. android:text="Suppr" />
  55.  
  56. <Button
  57. android:id="@+id/button22"
  58. android:layout_width="wrap_content"
  59. android:layout_height="wrap_content"
  60. android:backgroundTint="@android:color/holo_green_light"
  61. android:onClick="clicButton"
  62. android:text="AC" />
  63. </TableRow>
  64.  
  65. <TableRow
  66. android:layout_width="match_parent"
  67. android:layout_height="match_parent">
  68.  
  69. <Button
  70. android:id="@+id/button23"
  71. android:layout_width="wrap_content"
  72. android:layout_height="wrap_content"
  73. android:onClick="clicButton"
  74. android:text="4" />
  75.  
  76. <Button
  77. android:id="@+id/button6"
  78. android:layout_width="wrap_content"
  79. android:layout_height="wrap_content"
  80. android:onClick="clicButton"
  81. android:text="5" />
  82.  
  83. <Button
  84. android:id="@+id/button7"
  85. android:layout_width="wrap_content"
  86. android:layout_height="wrap_content"
  87. android:onClick="clicButton"
  88. android:text="6" />
  89.  
  90. <Button
  91. android:id="@+id/button8"
  92. android:layout_width="wrap_content"
  93. android:layout_height="wrap_content"
  94. android:onClick="clicButton"
  95. android:text="x" />
  96.  
  97. <Button
  98. android:id="@+id/button9"
  99. android:layout_width="wrap_content"
  100. android:layout_height="wrap_content"
  101. android:onClick="clicButton"
  102. android:text="รท" />
  103. </TableRow>
  104.  
  105. <TableRow
  106. android:layout_width="match_parent"
  107. android:layout_height="match_parent">
  108.  
  109. <Button
  110. android:id="@+id/button24"
  111. android:layout_width="wrap_content"
  112. android:layout_height="wrap_content"
  113. android:onClick="clicButton"
  114. android:text="1" />
  115.  
  116. <Button
  117. android:id="@+id/button10"
  118. android:layout_width="wrap_content"
  119. android:layout_height="wrap_content"
  120. android:onClick="clicButton"
  121. android:text="2" />
  122.  
  123. <Button
  124. android:id="@+id/button11"
  125. android:layout_width="wrap_content"
  126. android:layout_height="wrap_content"
  127. android:onClick="clicButton"
  128. android:text="3" />
  129.  
  130. <Button
  131. android:id="@+id/button12"
  132. android:layout_width="wrap_content"
  133. android:layout_height="wrap_content"
  134. android:onClick="clicButton"
  135. android:text="+" />
  136.  
  137. <Button
  138. android:id="@+id/button13"
  139. android:layout_width="wrap_content"
  140. android:layout_height="wrap_content"
  141. android:onClick="clicButton"
  142. android:text="-" />
  143. </TableRow>
  144.  
  145. <TableRow
  146. android:layout_width="match_parent"
  147. android:layout_height="match_parent">
  148.  
  149. <Button
  150. android:id="@+id/button25"
  151. android:layout_width="wrap_content"
  152. android:layout_height="wrap_content"
  153. android:onClick="clicButton"
  154. android:text="0" />
  155.  
  156. <Button
  157. android:id="@+id/button14"
  158. android:layout_width="wrap_content"
  159. android:layout_height="wrap_content"
  160. android:onClick="clicButton"
  161. android:text="," />
  162.  
  163. <Button
  164. android:id="@+id/button15"
  165. android:layout_width="wrap_content"
  166. android:layout_height="wrap_content"
  167. android:onClick="clicButton"
  168. android:text="=" />
  169. </TableRow>
  170. </TableLayout>
  171.  
  172. </android.support.constraint.ConstraintLayout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement