activity_custom_sign_pad.xml 4.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. android:layout_width="match_parent"
  4. android:layout_height="match_parent"
  5. android:layout_marginVertical="200dp"
  6. xmlns:app="http://schemas.android.com/apk/res-auto"
  7. android:background="@drawable/department_layer">
  8. <LinearLayout
  9. android:layout_width="match_parent"
  10. android:layout_height="match_parent"
  11. android:layout_centerInParent="true"
  12. android:background="@drawable/department_layer"
  13. android:orientation="vertical">
  14. <RelativeLayout
  15. android:layout_width="match_parent"
  16. android:layout_height="wrap_content"
  17. android:layout_margin="2dp"
  18. android:background="@color/commonColor">
  19. <TextView
  20. android:id="@+id/tvTitle"
  21. android:layout_width="match_parent"
  22. android:layout_height="wrap_content"
  23. android:layout_margin="12dp"
  24. android:text="@string/createSign"
  25. android:textColor="@color/white"
  26. android:textSize="20sp"
  27. android:textStyle="bold" />
  28. </RelativeLayout>
  29. <LinearLayout
  30. android:layout_width="match_parent"
  31. android:layout_height="match_parent"
  32. android:orientation="vertical"
  33. android:layout_marginTop="12dp"
  34. android:layout_marginLeft="14dp"
  35. android:layout_marginRight="14dp"
  36. android:weightSum="1">
  37. <LinearLayout
  38. android:id="@+id/signPadLayout"
  39. android:layout_width="match_parent"
  40. android:layout_height="match_parent"
  41. android:background="@drawable/sign_edge"
  42. android:layout_weight="0.25"
  43. android:layout_marginBottom="14dp"
  44. android:weightSum="4"
  45. android:orientation="vertical">
  46. <com.github.gcacace.signaturepad.views.SignaturePad
  47. android:id="@+id/signPad"
  48. android:layout_width="match_parent"
  49. android:layout_height="match_parent"
  50. android:layout_margin="12dp"
  51. app:penColor="@color/black" />
  52. </LinearLayout>
  53. <LinearLayout
  54. android:id="@+id/btnLayout"
  55. android:layout_width="match_parent"
  56. android:layout_height="match_parent"
  57. android:orientation="horizontal"
  58. android:layout_weight="0.75"
  59. android:layout_marginBottom="2dp"
  60. android:gravity="center"
  61. android:background="@xml/border_top">
  62. <Button
  63. android:id="@+id/btnConfirm"
  64. style="?android:attr/borderlessButtonStyle"
  65. android:layout_width="match_parent"
  66. android:layout_height="match_parent"
  67. android:layout_weight="1"
  68. android:layout_marginTop="14dp"
  69. android:layout_marginBottom="12dp"
  70. android:layout_marginLeft="48dp"
  71. android:layout_marginRight="10dp"
  72. android:background="@drawable/shape2"
  73. android:textColor="@color/white"
  74. android:textSize="16sp"
  75. android:text="@string/confirm"/>
  76. <Button
  77. android:id="@+id/btnInit"
  78. style="?android:attr/borderlessButtonStyle"
  79. android:layout_width="match_parent"
  80. android:layout_height="match_parent"
  81. android:layout_weight="1"
  82. android:layout_marginTop="14dp"
  83. android:layout_marginBottom="12dp"
  84. android:layout_marginLeft="10dp"
  85. android:layout_marginRight="48dp"
  86. android:text="@string/initialize"
  87. android:textColor="@color/white"
  88. android:textSize="16sp"
  89. android:background="@drawable/shape2" />
  90. </LinearLayout>
  91. </LinearLayout>
  92. </LinearLayout>
  93. </RelativeLayout>