ConstraintLayout is behaving inconsistently if a TextView has very fewer texts than other TextView wrapped in horizontal LinearLayout. If a character in left TextView is not much less than right TextView then it is working great.
Please refer red color texts and green color texts in attached screenshots.
Below is the XML for layout:
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/color_F1F1F1"
android:padding="10dp">
<android.support.constraint.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#color/white"
android:padding="10dp">
<TextView
android:id="#+id/tv_name_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="#string/employee_name"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/tv_date_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="#string/date"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/tv_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_name_header" />
<TextView
android:id="#+id/tv_date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_date_header" />
<TextView
android:id="#+id/tv_role_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/employee_role"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_name" />
<TextView
android:id="#+id/tv_band_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/employee_band"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_date" />
<TextView
android:id="#+id/tv_role"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_role_header" />
<TextView
android:id="#+id/tv_band"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_band_header" />
<View
android:id="#+id/view_divider"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_marginTop="15dp"
android:background="#color/color_E1E4EA"
app:layout_constraintTop_toBottomOf="#id/tv_role" />
<LinearLayout
android:id="#+id/ll_address"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/view_divider">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginTop="3dp"
android:background="#drawable/circle_shape_green" />
<TextView
android:id="#+id/tv_origin_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:text=""
android:textColor="#color/black"
android:textSize="13sp" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginLeft="5dp"
android:layout_marginTop="3dp"
android:background="#drawable/circle_shape_red" />
<TextView
android:id="#+id/tv_destination_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="5dp"
android:gravity="right"
android:text=""
android:textColor="#color/black"
android:textSize="13sp" />
</LinearLayout>
</LinearLayout>
<TextView
android:id="#+id/tv_justification_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/justification"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/ll_address" />
<TextView
android:id="#+id/tv_justification"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_justification_header" />
<TextView
android:id="#+id/tv_vehicle_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/vehicle_type"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_justification" />
<TextView
android:id="#+id/tv_vehicle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_vehicle_header" />
<TextView
android:id="#+id/tv_Duration_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/distance"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_justification" />
<TextView
android:id="#+id/tv_duration"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_Duration_header" />
<TextView
android:id="#+id/tv_start_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/start_time"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_vehicle" />
<TextView
android:id="#+id/tv_end_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/end_time"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_duration" />
<TextView
android:id="#+id/tv_start_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_start_time_header" />
<TextView
android:id="#+id/tv_end_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_end_time_header" />
<TextView
android:id="#+id/tv_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/trip_distance"
android:textColor="#color/color_999999"
android:textSize="12sp"
app:layout_constraintTop_toBottomOf="#id/tv_start_time" />
<TextView
android:id="#+id/tv_edited_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/edited_distance"
android:textColor="#color/color_999999"
android:textSize="12sp"
android:visibility="gone"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_end_time" />
<TextView
android:id="#+id/tv_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_distance_header" />
<TextView
android:id="#+id/tv_edited_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/color_D15900"
android:textSize="14sp"
android:textStyle="bold"
android:visibility="gone"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_edited_distance_header" />
<TextView
android:id="#+id/tv_edit_reason"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:textSize="14sp"
android:visibility="gone"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_distance" />
<LinearLayout
android:id="#+id/ll_reject_reason"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:orientation="vertical"
android:visibility="gone"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#id/tv_edit_reason">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="#string/manager_reject_reason"
android:textColor="#color/color_999999"
android:textSize="12sp" />
<TextView
android:id="#+id/tv_rejection_reason"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text=""
android:textColor="#color/black"
android:textSize="14sp" />
</LinearLayout>
<Button
android:id="#+id/bt_back"
style="#style/FlatButton"
android:layout_width="wrap_content"
android:layout_height="35dp"
android:layout_marginTop="15dp"
android:gravity="left|center_vertical"
android:paddingLeft="0dp"
android:text="#string/back"
android:textAllCaps="true"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/ll_reject_reason" />
</android.support.constraint.ConstraintLayout>
</android.support.v4.widget.NestedScrollView>
Please ignore my English.
There are some bugs regarding wrap_content in constraintLayout version 1.0.2 as per google developer whom I talked. He suggested to use 1.1.0-beta4 version and by using version 1.1.0-beta4 my issue has been fixed.
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#F1F1F1">
<android.support.constraint.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#ffffff"
android:layout_margin = "10dp">
<TextView
android:id="#+id/tv_name_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="employee_name"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toTopOf="#+id/tv_name"
/>
<TextView
android:id="#+id/tv_date_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="date_header"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintLeft_toRightOf="#+id/tv_name_header"
app:layout_constraintBottom_toTopOf="#+id/tv_date"/>
<TextView
android:id="#+id/tv_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="name"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_name_header"
app:layout_constraintBottom_toTopOf="#+id/tv_role_header"
/>
<TextView
android:id="#+id/tv_date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="date"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintTop_toBottomOf="#+id/tv_date_header"
app:layout_constraintLeft_toLeftOf="#+id/tv_date_header"
app:layout_constraintBottom_toTopOf="#+id/tv_band_header"
/>
<TextView
android:id="#+id/tv_role_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="employee_role"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_name"
app:layout_constraintTop_toBottomOf="#+id/tv_name" />
<TextView
android:id="#+id/tv_band_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="11dp"
android:text="employee_band"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_date"
app:layout_constraintTop_toBottomOf="#+id/tv_date"
/>
<TextView
android:id="#+id/tv_role"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="role"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="#+id/tv_role_header"
app:layout_constraintTop_toBottomOf="#+id/tv_role_header" />
<TextView
android:id="#+id/tv_band"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="band"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="#+id/tv_band_header"
app:layout_constraintTop_toBottomOf="#+id/tv_band_header" />
<View
android:id="#+id/view_divider"
android:layout_width="0dp"
android:layout_height="1dp"
android:layout_marginTop="15dp"
android:background="#E1E4EA"
app:layout_constraintTop_toBottomOf="#+id/tv_role"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintLeft_toLeftOf="parent"/>
<LinearLayout
android:id="#+id/ll_address"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/view_divider">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginTop="3dp"
/>
<TextView
android:id="#+id/tv_origin_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:text="origin_address \n origin_address"
android:textColor="#000000"
android:textSize="13sp" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginLeft="5dp"
android:layout_marginTop="3dp"
/>
<TextView
android:id="#+id/tv_destination_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="5dp"
android:gravity="right"
android:text="destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address "
android:textColor="#000000"
android:textSize="13sp" />
</LinearLayout>
</LinearLayout>
<TextView
android:id="#+id/tv_justification_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="justification_header"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/ll_address" />
<TextView
android:id="#+id/tv_justification"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="justification"
android:textColor="#000000"
android:textSize="14sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_justification_header"
app:layout_constraintTop_toBottomOf="#+id/tv_justification_header" />
<TextView
android:id="#+id/tv_vehicle_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="vehicle_type"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_justification" />
<TextView
android:id="#+id/tv_vehicle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="vehicle"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_vehicle_header" />
<TextView
android:id="#+id/tv_Duration_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="distance"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_justification" />
<TextView
android:id="#+id/tv_duration"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="duration"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_Duration_header" />
<TextView
android:id="#+id/tv_start_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="start_time"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_vehicle" />
<TextView
android:id="#+id/tv_end_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="end_time"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_duration" />
<TextView
android:id="#+id/tv_start_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="start_time"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_start_time_header" />
<TextView
android:id="#+id/tv_end_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="end_time"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_end_time_header" />
<TextView
android:id="#+id/tv_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="trip_distance"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintTop_toBottomOf="#+id/tv_start_time"
app:layout_constraintLeft_toLeftOf="parent"/>
<TextView
android:id="#+id/tv_edited_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="edited_distance"
android:textColor="#999999"
android:textSize="12sp"
android:visibility="gone"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_end_time" />
<TextView
android:id="#+id/tv_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="distance"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_distance_header" />
<TextView
android:id="#+id/tv_edited_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="edited_distance"
android:textColor="#D15900"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_edited_distance_header" />
<TextView
android:id="#+id/tv_edit_reason"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="14sp"
android:text="edit_reason"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_distance" />
<LinearLayout
android:id="#+id/ll_reject_reason"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_edit_reason">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="manager_reject_reason"
android:textColor="#999999"
android:textSize="12sp" />
<TextView
android:id="#+id/tv_rejection_reason"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="rejection_reason"
android:textColor="#000000"
android:textSize="14sp" />
</LinearLayout>
<Button
android:id="#+id/bt_back"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="14dp"
android:gravity="center"
android:text="Back"
android:textAllCaps="true"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/ll_reject_reason"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginLeft="12dp"
android:layout_marginBottom="14dp"
android:layout_marginStart="12dp"/>
</android.support.constraint.ConstraintLayout>
</android.support.v4.widget.NestedScrollView>
You need to add constraint bottom to your button,something like this
<Button
android:id="#+id/bt_back"
android:layout_width="wrap_content"
android:layout_height="35dp"
android:gravity="left|center_vertical"
android:paddingLeft="0dp"
android:text="back"
android:textAllCaps="true"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#id/ll_reject_reason"
app:layout_constraintVertical_bias="0.0" />
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#F1F1F1"
>
<android.support.v4.widget.NestedScrollView
android:id="#+id/NestedScrollView"
android:layout_width="0dp"
android:layout_height="0dp"
app:layout_constraintBottom_toTopOf="#+id/bt_back"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="parent">
<android.support.constraint.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#ffffff"
android:layout_margin = "10dp">
<TextView
android:id="#+id/tv_name_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="employee_name"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toTopOf="#+id/tv_name"
/>
<TextView
android:id="#+id/tv_date_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="date_header"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintLeft_toRightOf="#+id/tv_name_header"
app:layout_constraintBottom_toTopOf="#+id/tv_date"/>
<TextView
android:id="#+id/tv_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="name"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_name_header"
app:layout_constraintBottom_toTopOf="#+id/tv_role_header"
/>
<TextView
android:id="#+id/tv_date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="date"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintTop_toBottomOf="#+id/tv_date_header"
app:layout_constraintLeft_toLeftOf="#+id/tv_date_header"
app:layout_constraintBottom_toTopOf="#+id/tv_band_header"
/>
<TextView
android:id="#+id/tv_role_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="employee_role"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_name"
app:layout_constraintTop_toBottomOf="#+id/tv_name" />
<TextView
android:id="#+id/tv_band_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="11dp"
android:text="employee_band"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_date"
app:layout_constraintTop_toBottomOf="#+id/tv_date"
/>
<TextView
android:id="#+id/tv_role"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="role"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="#+id/tv_role_header"
app:layout_constraintTop_toBottomOf="#+id/tv_role_header" />
<TextView
android:id="#+id/tv_band"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="band"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="#+id/tv_band_header"
app:layout_constraintTop_toBottomOf="#+id/tv_band_header" />
<View
android:id="#+id/view_divider"
android:layout_width="0dp"
android:layout_height="1dp"
android:layout_marginTop="15dp"
android:background="#E1E4EA"
app:layout_constraintTop_toBottomOf="#+id/tv_role"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintLeft_toLeftOf="parent"/>
<LinearLayout
android:id="#+id/ll_address"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/view_divider">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginTop="3dp"
/>
<TextView
android:id="#+id/tv_origin_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:text="origin_address \n origin_address"
android:textColor="#000000"
android:textSize="13sp" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:orientation="horizontal">
<TextView
android:layout_width="15dp"
android:layout_height="15dp"
android:layout_marginLeft="5dp"
android:layout_marginTop="3dp"
/>
<TextView
android:id="#+id/tv_destination_address"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="5dp"
android:gravity="right"
android:text="destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address \n destination_address "
android:textColor="#000000"
android:textSize="13sp" />
</LinearLayout>
</LinearLayout>
<TextView
android:id="#+id/tv_justification_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="justification_header"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/ll_address" />
<TextView
android:id="#+id/tv_justification"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="justification"
android:textColor="#000000"
android:textSize="14sp"
app:layout_constraintLeft_toLeftOf="#+id/tv_justification_header"
app:layout_constraintTop_toBottomOf="#+id/tv_justification_header" />
<TextView
android:id="#+id/tv_vehicle_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="vehicle_type"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_justification" />
<TextView
android:id="#+id/tv_vehicle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="vehicle"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_vehicle_header" />
<TextView
android:id="#+id/tv_Duration_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="distance"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_justification" />
<TextView
android:id="#+id/tv_duration"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="duration"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_Duration_header" />
<TextView
android:id="#+id/tv_start_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="start_time"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_vehicle" />
<TextView
android:id="#+id/tv_end_time_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="end_time"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_duration" />
<TextView
android:id="#+id/tv_start_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="start_time"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_start_time_header" />
<TextView
android:id="#+id/tv_end_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="end_time"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_end_time_header" />
<TextView
android:id="#+id/tv_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="trip_distance"
android:textColor="#999999"
android:textSize="12sp"
app:layout_constraintTop_toBottomOf="#+id/tv_start_time"
app:layout_constraintLeft_toLeftOf="parent"/>
<TextView
android:id="#+id/tv_edited_distance_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="edited_distance"
android:textColor="#999999"
android:textSize="12sp"
android:visibility="gone"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_end_time" />
<TextView
android:id="#+id/tv_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="distance"
android:textColor="#000000"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_distance_header" />
<TextView
android:id="#+id/tv_edited_distance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="edited_distance"
android:textColor="#D15900"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_edited_distance_header" />
<TextView
android:id="#+id/tv_edit_reason"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="14sp"
android:text="edit_reason"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_distance" />
<LinearLayout
android:id="#+id/ll_reject_reason"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="#+id/tv_edit_reason"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginBottom="10dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="manager_reject_reason"
android:textColor="#999999"
android:textSize="12sp" />
<TextView
android:id="#+id/tv_rejection_reason"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="rejection_reason"
android:textColor="#000000"
android:textSize="14sp" />
</LinearLayout>
</android.support.constraint.ConstraintLayout>
</android.support.v4.widget.NestedScrollView>
<Button
android:id="#+id/bt_back"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:gravity="center"
android:text="Back"
android:textAllCaps="true"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/NestedScrollView"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginLeft="12dp"
android:layout_marginBottom="10dp"
android:layout_marginStart="12dp"/>
</android.support.constraint.ConstraintLayout>
Related
When I make changes to the design screen, I cannot see it in the emulator.my goal is to fix the timers.but whatever change I make on the design screen, I can't see that change in the emulator.The timers in the emulator always look the same.
here are my codes;
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#fffdd0"
tools:context=".MainActivity">
<android.support.constraint.Guideline
android:id="#+id/guidelineV1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.95" />
<android.support.constraint.Guideline
android:id="#+id/guidelineV2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.05" />
<android.support.constraint.Guideline
android:id="#+id/guidelineH1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.98" />
<android.support.constraint.Guideline
android:id="#+id/guidelineH2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.02">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.12">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.4">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.85">
</android.support.constraint.Guideline>
<Button
android:id="#+id/btn_kalp1"
android:layout_width="50dp"
android:layout_height="40dp"
android:layout_alignParentStart="true"
android:background="#drawable/kalp"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_kalp1" />
<TextView
android:id="#+id/textView3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginStart="55dp"
android:layout_marginTop="20dp"
android:text="X"
android:textColor="#color/colorPrimary"
android:textSize="10sp"
app:layout_constraintStart_toStartOf="#+id/btn_kalp1"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_kalp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:text="5"
android:textColor="#color/colorPrimary"
android:textSize="20sp"
app:layout_constraintStart_toStartOf="#+id/textView3"
app:layout_constraintTop_toTopOf="#id/guidelineH2" />
<Button
android:id="#+id/btn_double"
android:layout_width="0dp"
android:layout_height="47dp"
android:layout_marginStart="40dp"
android:layout_marginEnd="0dp"
android:background="#drawable/xx"
app:layout_constraintEnd_toStartOf="#+id/btn_yariyariya"
app:layout_constraintStart_toStartOf="#+id/tv_kalp"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown2x"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="110dp"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#id/guidelineV2"
app:layout_constraintTop_toBottomOf="#id/btn_double" />
<Button
android:id="#+id/btn_yariyariya"
android:layout_width="0dp"
android:layout_height="49dp"
android:layout_marginStart="0dp"
android:layout_marginEnd="0dp"
android:background="#drawable/fiftyfifty"
app:layout_constraintEnd_toStartOf="#+id/btn_skip"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toEndOf="#+id/btn_double"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown50"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toEndOf="#id/tv_countdown2x"
app:layout_constraintTop_toBottomOf="#+id/btn_yariyariya"/>
<Button
android:id="#+id/btn_skip"
android:layout_width="0dp"
android:layout_height="45dp"
android:layout_marginStart="0dp"
android:layout_marginTop="1dp"
android:layout_marginEnd="40dp"
android:background="#drawable/skip"
app:layout_constraintEnd_toStartOf="#+id/btn_satinal"
app:layout_constraintStart_toEndOf="#+id/btn_yariyariya"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdownNext"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toEndOf="#id/tv_countdown50"
app:layout_constraintTop_toBottomOf="#+id/btn_skip" />
<FrameLayout
android:id="#+id/container_pop_up"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<Button
android:id="#+id/btn_satinal"
android:layout_width="50dp"
android:layout_height="40dp"
android:background="#drawable/satinal"
android:onClick="satinalMain"
app:layout_constraintEnd_toStartOf="#+id/guidelineV1"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:textColor="#color/colorPrimary"
android:textSize="30sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/guidelineH3"
tools:text="00:30" />
<TextView
android:id="#+id/tv_soru"
android:layout_width="0dp"
android:layout_height="0dp"
android:fontFamily="#font/incee"
android:gravity="center"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="18sp"
app:layout_constraintBottom_toTopOf="#+id/guidelineH4"
app:layout_constraintEnd_toEndOf="#id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/tv_countdown" />
<Button
android:id="#+id/btn_a"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="20dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:shadowColor="#E91E63"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_b"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toTopOf="#+id/guidelineH4" />
<Button
android:id="#+id/btn_b"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_c"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_a" />
<Button
android:id="#+id/btn_c"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_d"
app:layout_constraintEnd_toEndOf="#id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_b" />
<Button
android:id="#+id/btn_d"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="60dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/guidelineH5"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_c"
app:layout_constraintVertical_bias="0.0" />
<Button
android:id="#+id/btn_infoA"
android:layout_width="50dp"
android:layout_height="50dp"
android:background="#drawable/info"
app:layout_constraintBottom_toTopOf="#+id/guidelineH5"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent" />
<Button
android:id="#+id/btn_gec"
android:layout_width="75dp"
android:layout_height="70dp"
android:background="#drawable/next"
app:layout_constraintBottom_toTopOf="#id/guidelineH5"
app:layout_constraintEnd_toStartOf="#id/guidelineV1" />
<com.google.android.gms.ads.AdView
android:id="#+id/adView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:adSize="BANNER"
app:adUnitId="ca-app-pub-3101578796185185/4912585915"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent">
</com.google.android.gms.ads.AdView>
<Button
android:id="#+id/btn_reklam"
android:layout_width="50dp"
android:layout_height="45dp"
android:background="#drawable/plus"
android:onClick="startVideoAd"
app:layout_constraintStart_toStartOf="#id/guidelineV2"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/tv_kalp_kazan"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="55dp"
android:layout_marginTop="15dp"
android:layout_marginBottom="5dp"
android:fontFamily="#font/incee"
android:text="İzle Kazan"
android:textColor="#000"
android:textSize="15sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#id/guidelineV2"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:layout_marginEnd="50dp"
android:text="SKOR :"
android:textColor="#000"
android:textSize="15sp"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="#id/guidelineV1"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/tv_skor"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:layout_marginEnd="25dp"
android:text="0"
android:textColor="#000"
android:textSize="25sp"
app:layout_constraintEnd_toStartOf="#id/guidelineV1"
app:layout_constraintTop_toBottomOf="#id/guidelineH5"
/>
I'm just learning design.I am trying to make responsive design.
I hope this answer will help you. If you have any query please let me know, :).
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#fffdd0"
tools:context=".MainActivity">
<android.support.constraint.Guideline
android:id="#+id/guidelineV1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.95" />
<android.support.constraint.Guideline
android:id="#+id/guidelineV2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.05" />
<android.support.constraint.Guideline
android:id="#+id/guidelineH1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.98" />
<android.support.constraint.Guideline
android:id="#+id/guidelineH2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.02">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.12">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.4">
</android.support.constraint.Guideline>
<android.support.constraint.Guideline
android:id="#+id/guidelineH5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.85">
</android.support.constraint.Guideline>
<Button
android:id="#+id/btn_kalp1"
android:layout_width="50dp"
android:layout_height="40dp"
android:layout_alignParentStart="true"
android:background="#drawable/kalp"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_kalp1" />
<TextView
android:id="#+id/textView3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginStart="55dp"
android:layout_marginTop="20dp"
android:text="X"
android:textColor="#color/colorPrimary"
android:textSize="10sp"
app:layout_constraintStart_toStartOf="#+id/btn_kalp1"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_kalp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:text="5"
android:textColor="#color/colorPrimary"
android:textSize="20sp"
app:layout_constraintStart_toStartOf="#+id/textView3"
app:layout_constraintTop_toTopOf="#id/guidelineH2" />
<Button
android:id="#+id/btn_double"
android:layout_width="42dp"
android:layout_height="47dp"
android:background="#drawable/xx"
android:text="2X"
app:layout_constraintHorizontal_chainStyle="packed"
app:layout_constraintEnd_toStartOf="#+id/btn_yariyariya"
app:layout_constraintStart_toStartOf="#+id/tv_kalp"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown2x"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#id/btn_double"
app:layout_constraintEnd_toEndOf="#id/btn_double"
app:layout_constraintTop_toBottomOf="#id/btn_double" />
<Button
android:id="#+id/btn_yariyariya"
android:layout_width="42dp"
android:layout_height="49dp"
android:text="50"
android:background="#drawable/fiftyfifty"
app:layout_constraintEnd_toStartOf="#+id/btn_skip"
app:layout_constraintStart_toEndOf="#+id/btn_double"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown50"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#id/btn_yariyariya"
app:layout_constraintEnd_toEndOf="#id/btn_yariyariya"
app:layout_constraintBaseline_toBaselineOf="#id/tv_countdown2x"/>
<Button
android:id="#+id/btn_skip"
android:layout_width="42dp"
android:layout_height="45dp"
android:background="#drawable/skip"
app:layout_constraintEnd_toStartOf="#+id/btn_satinal"
app:layout_constraintStart_toEndOf="#+id/btn_yariyariya"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdownNext"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="00:00"
android:textColor="#color/colorPrimary"
android:textSize="14sp"
app:layout_constraintStart_toStartOf="#id/btn_skip"
app:layout_constraintEnd_toEndOf="#id/btn_skip"
app:layout_constraintBaseline_toBaselineOf="#id/tv_countdown2x" />
<FrameLayout
android:id="#+id/container_pop_up"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<Button
android:id="#+id/btn_satinal"
android:layout_width="50dp"
android:layout_height="40dp"
android:background="#drawable/satinal"
android:onClick="satinalMain"
app:layout_constraintEnd_toStartOf="#+id/guidelineV1"
app:layout_constraintTop_toTopOf="#+id/guidelineH2" />
<TextView
android:id="#+id/tv_countdown"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:textColor="#color/colorPrimary"
android:textSize="30sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/guidelineH3"
tools:text="00:30" />
<TextView
android:id="#+id/tv_soru"
android:layout_width="0dp"
android:layout_height="0dp"
android:fontFamily="#font/incee"
android:gravity="center"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="18sp"
app:layout_constraintBottom_toTopOf="#+id/guidelineH4"
app:layout_constraintEnd_toEndOf="#id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/tv_countdown" />
<Button
android:id="#+id/btn_a"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="20dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:shadowColor="#E91E63"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_b"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toTopOf="#+id/guidelineH4" />
<Button
android:id="#+id/btn_b"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_c"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_a" />
<Button
android:id="#+id/btn_c"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="5dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/btn_d"
app:layout_constraintEnd_toEndOf="#id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_b" />
<Button
android:id="#+id/btn_d"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="60dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="60dp"
android:background="#drawable/gradient"
android:elegantTextHeight="true"
android:fontFamily="#font/incee"
android:textAlignment="gravity"
android:textColor="#000"
android:textSize="12sp"
app:layout_constraintBottom_toTopOf="#+id/guidelineH5"
app:layout_constraintEnd_toEndOf="#+id/guidelineV1"
app:layout_constraintStart_toStartOf="#+id/guidelineV2"
app:layout_constraintTop_toBottomOf="#+id/btn_c"
app:layout_constraintVertical_bias="0.0" />
<Button
android:id="#+id/btn_infoA"
android:layout_width="50dp"
android:layout_height="50dp"
android:background="#drawable/info"
app:layout_constraintBottom_toTopOf="#+id/guidelineH5"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent" />
<Button
android:id="#+id/btn_gec"
android:layout_width="75dp"
android:layout_height="70dp"
android:background="#drawable/next"
app:layout_constraintBottom_toTopOf="#id/guidelineH5"
app:layout_constraintEnd_toStartOf="#id/guidelineV1" />
<com.google.android.gms.ads.AdView
android:id="#+id/adView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:adSize="BANNER"
app:adUnitId="ca-app-pub-3101578796185185/4912585915"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent">
</com.google.android.gms.ads.AdView>
<Button
android:id="#+id/btn_reklam"
android:layout_width="50dp"
android:layout_height="45dp"
android:background="#drawable/plus"
android:onClick="startVideoAd"
app:layout_constraintStart_toStartOf="#id/guidelineV2"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/tv_kalp_kazan"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="55dp"
android:layout_marginTop="15dp"
android:layout_marginBottom="5dp"
android:fontFamily="#font/incee"
android:text="İzle Kazan"
android:textColor="#000"
android:textSize="15sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#id/guidelineV2"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="15dp"
android:layout_marginEnd="50dp"
android:text="SKOR :"
android:textColor="#000"
android:textSize="15sp"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="#id/guidelineV1"
app:layout_constraintTop_toBottomOf="#id/guidelineH5" />
<TextView
android:id="#+id/tv_skor"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:layout_marginEnd="25dp"
android:text="0"
android:textColor="#000"
android:textSize="25sp"
app:layout_constraintEnd_toStartOf="#id/guidelineV1"
app:layout_constraintTop_toBottomOf="#id/guidelineH5"
/>
</android.support.constraint.ConstraintLayout>
I have tried various other methods such as using nested scrollview, removed bottom_of_bottom="parent" and other solutions that are provided here but none of them seem to have been worked, anyone knows how to tackle this one, please share your solution? Been 2 days stuck on this.
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="700dp"
android:fillViewport="true"
tools:context="com.example.genmypassword.MainActivity">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:isScrollContainer="true">
<EditText
android:id="#+id/login_text_phone2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="50dp"
android:background="#android:color/transparent"
android:digits="0123456789"
android:hint="default: 1"
android:maxLength="20"
app:layout_constraintHorizontal_bias="0.578"
app:layout_constraintLeft_toLeftOf="#id/textView12"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.066" />
<TextView
android:id="#+id/textView12"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#E8FFEB3B"
android:shadowColor="#FFEB3B"
android:text="Number of passwords"
android:textColor="#009688"
android:textColorHighlight="#FFEB3B"
android:textStyle="bold"
app:layout_constraintBottom_toBottomOf="#id/textView"
app:layout_constraintHorizontal_bias="0.058"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.552" />
<CheckBox
android:id="#+id/checkBox11"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="325dp"
android:text="front"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.242"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.485" />
<CheckBox
android:id="#+id/checkBox13"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="325dp"
android:text="in between"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.785"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.485" />
<CheckBox
android:id="#+id/checkBox12"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="325dp"
android:text="End"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.475"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.485" />
<CheckBox
android:id="#+id/checkBox7"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="375dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.593"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.683" />
<CheckBox
android:id="#+id/checkBox6"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="350dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.593"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.636" />
<CheckBox
android:id="#+id/checkBox4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="270dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.593"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.46" />
<CheckBox
android:id="#+id/checkBox3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="250dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.593"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.419" />
<TextView
android:id="#+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="75dp"
android:background="#E8FFEB3B"
android:shadowColor="#FFEB3B"
android:text="Password length(Security)"
android:textColor="#009688"
android:textColorHighlight="#FFEB3B"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.119" />
<TextView
android:id="#+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="40dp"
android:background="#E8FFEB3B"
android:text="alphanumeric"
android:textColor="#009688"
android:textColorHighlight="#FFEB3B"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.049"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="#id/textView"
app:layout_constraintVertical_bias="0.059" />
<TextView
android:id="#+id/textView3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="40dp"
android:background="#E8FFEB3B"
android:text="PIN(numeric)"
android:textColor="#009688"
android:textColorHighlight="#FFEB3B"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.048"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="#id/textView2"
app:layout_constraintVertical_bias="0.07" />
<TextView
android:id="#+id/textView4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="50dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Must Contain(default Alphanumeric):"
android:textColor="#3F51B5"
android:textColorHighlight="#FFFFFF"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView3"
app:layout_constraintVertical_bias="0.127" />
<TextView
android:id="#+id/textView5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="50dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Upper Case"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView4"
app:layout_constraintVertical_bias="0.127" />
<TextView
android:id="#+id/textView6"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="25dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Lower Case"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView5"
app:layout_constraintVertical_bias="0.069" />
<TextView
android:id="#+id/textView7"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="25dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Passphrase"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView6"
app:layout_constraintVertical_bias="0.075" />
<TextView
android:id="#+id/textView8"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="50dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Special Characters"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView7"
app:layout_constraintVertical_bias="0.26" />
<TextView
android:id="#+id/textView9"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="25dp"
android:background="#E8FFFFFF"
android:shadowColor="#FFEB3B"
android:text="Numbers"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView8"
app:layout_constraintVertical_bias="0.129" />
<Button
android:id="#+id/button"
android:layout_width="180dp"
android:layout_height="30dp"
android:layout_marginTop="530dp"
android:background="#8BC34A"
android:text="GENERATE AND COPY"
app:layout_constraintHorizontal_bias="0.49"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.905" />
<Button
android:id="#+id/button2"
android:layout_width="180dp"
android:layout_height="30dp"
android:layout_marginTop="40dp"
android:background="#8BC34A"
android:onClick="save"
android:text="GENERATE COPY SAVE"
app:layout_constraintHorizontal_bias="0.49"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="#id/button" />
<CheckBox
android:id="#+id/checkBox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="150dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.595"
app:layout_constraintLeft_toLeftOf="#id/textView2"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.22" />
<CheckBox
android:id="#+id/checkBox2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="115dp"
android:text="Tick for Yes"
android:textStyle="bold|italic"
app:layout_constraintHorizontal_bias="0.595"
app:layout_constraintLeft_toLeftOf="#id/textView3"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.174" />
<EditText
android:id="#+id/editText2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="12dp"
android:ems="10"
android:hint="Enter your text (Optional)"
android:inputType="textPersonName"
app:layout_constraintHorizontal_bias="0.947"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="#id/checkBox4" />
<EditText
android:id="#+id/login_text_phone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="80dp"
android:background="#android:color/transparent"
android:digits="0123456789"
android:hint="Enter the size (default: 8)"
android:maxLength="10"
app:layout_constraintHorizontal_bias="0.722"
app:layout_constraintLeft_toLeftOf="#id/textView"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<EditText
android:id="#+id/textView10"
android:layout_width="275dp"
android:layout_height="50dp"
android:layout_marginStart="200dp"
android:layout_marginLeft="200dp"
android:layout_marginTop="44dp"
android:background="#E8FFFFFF"
android:scrollbars="horizontal"
android:shadowColor="#FFEB3B"
android:text="see your password(s) here"
android:textColor="#000000"
android:textColorHighlight="#009688"
android:textSize="30sp"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#id/textView9" />
<TextView
android:id="#+id/textViewlast"
android:layout_width="150dp"
android:layout_height="26dp"
android:layout_marginStart="100dp"
android:layout_marginLeft="52dp"
android:layout_marginTop="60dp"
android:textColor="#color/colorPrimaryDark"
android:textSize="20sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.37"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/textView10" />
<TextView
android:id="#+id/textView11"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginTop="330dp"
android:text="Position:"
android:textColor="#4E0F00"
android:textColorHighlight="#FFEB3B"
android:textStyle="bold"
android:typeface="serif"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="#id/checkBox11"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.55" />
<Button
android:id="#+id/button3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="450dp"
android:background="#android:color/holo_orange_dark"
android:text="load"
android:textStyle="bold"
app:layout_constraintHorizontal_bias="0.061"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="#id/button2"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.973" />
</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>
unable to scroll down
Use Nested Scroll view like the
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/colorPrimary">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="16dp"
android:background="#color/colorPrimary"
android:orientation="vertical"
>
// Your code here
</LinearLayout>
</androidx.core.widget.NestedScrollView>
You need not fixed the height of ScrollView try to set its height as match_parent instead of 700dp-
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true">
There are two problems .
1) you need to change your scroll view from android:layout_height="700dp" to android:layout_height="match_parent".
2) you need to change your ConstraintLayout from android:layout_height="match_parent" to android:layout_height="wrap_content".
Hope this will solve your problem .
This is my first ask on StackOverflow. a Greetings.
I am using Android Studio, I'm trying to make a Layout that the textView is just below and centered on another TextView. Actually, I have it like this.
Want to ask how I can do something like this:
To center it and be "responsive" with the superior text view. Thank you so much.
this is the code:
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:padding="#dimen/activity_horizontal_margin">
<ImageView
android:id="#+id/imgPartidasRecomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginEnd="#dimen/activity_horizontal_margin"
android:src="#drawable/ic_star" />
<TextView
android:id="#+id/tv_perfil_partidasJugadas"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="#dimen/activity_horizontal_margin"
android:layout_toEndOf="#id/imgPartidasRecomendaciones"
android:background="#android:color/transparent"
android:text="Partidas"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_perfil_recomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="60dp"
android:layout_toEndOf="#id/tv_perfil_partidasJugadas"
android:background="#android:color/transparent"
android:text="Recomendaciones"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_partidasJugadasNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/tv_perfil_partidasJugadas"
android:layout_alignParentBottom="true"
android:layout_marginStart="#dimen/activity_horizontal_margin"
android:layout_toEndOf="#id/imgPartidasRecomendaciones"
android:layout_marginBottom="10dp"
android:text="0"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
<TextView
android:id="#+id/tv_recomendacionesNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/tv_perfil_partidasJugadas"
android:layout_alignParentBottom="true"
android:layout_marginStart="60dp"
android:layout_toEndOf="#id/tv_partidasJugadasNumber"
android:layout_marginBottom="10dp"
android:text="0"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
</RelativeLayout>
The solution is to wrap each pair of TextViews inside a vertical LinearLayout:
<ImageView
android:id="#+id/imgPartidasRecomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginEnd="#dimen/activity_horizontal_margin"
android:src="#drawable/ic_star" />
<LinearLayout
android:id="#+id/leftLayout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="#dimen/activity_horizontal_margin"
android:layout_marginBottom="10dp"
android:layout_toEndOf="#id/imgPartidasRecomendaciones"
android:orientation="vertical">
<TextView
android:id="#+id/tv_perfil_partidasJugadas"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#android:color/transparent"
android:text="Partidas"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_partidasJugadasNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="#dimen/activity_horizontal_margin"
android:text="0"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
</LinearLayout>
<LinearLayout
android:id="#+id/rightLayout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_toEndOf="#id/leftLayout"
android:layout_marginStart="60dp"
android:layout_marginBottom="10dp">
<TextView
android:id="#+id/tv_perfil_recomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#android:color/transparent"
android:text="Recomendaciones"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_recomendacionesNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="60dp"
android:text="0"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
</LinearLayout>
</RelativeLayout>
You can put every pair of textViews inside vertical LinearLayout but you better use constraint layout - it is a better layout for responsive screen building and easy to integrate with, here is a good example of using it:
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="#+id/textView10"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:background="#color/buttonColor"
android:text="view"
android:textColor="#color/textMainColour"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="#+id/guideline2"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView4"
android:layout_width="wrap_content"
android:layout_height="19dp"
android:layout_marginStart="20dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:background="#color/buttonColor"
android:text="view"
android:textColor="#color/textMainColour"
app:layout_constraintBottom_toTopOf="#+id/textView10"
app:layout_constraintEnd_toStartOf="#+id/guideline3"
app:layout_constraintStart_toStartOf="#+id/guideline2" />
<TextView
android:id="#+id/textView5"
android:layout_width="0dp"
android:layout_height="21dp"
android:layout_marginTop="8dp"
android:background="#color/buttonColor"
android:text="view"
android:textColor="#color/textMainColour"
app:layout_constraintEnd_toEndOf="#+id/textView4"
app:layout_constraintStart_toStartOf="#+id/textView4"
app:layout_constraintTop_toBottomOf="#+id/textView10" />
<TextView
android:id="#+id/textView9"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#color/buttonColor"
android:text="view"
android:textColor="#color/textMainColour"
app:layout_constraintBottom_toBottomOf="#+id/textView5"
app:layout_constraintEnd_toEndOf="#+id/textView8"
app:layout_constraintStart_toStartOf="#+id/textView8"
app:layout_constraintTop_toTopOf="#+id/textView5"
app:layout_constraintVertical_bias="0.0" />
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guideline2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_begin="55dp"
app:layout_constraintGuide_percent="0.2" />
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guideline3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_begin="146dp"
app:layout_constraintGuide_percent="0.6" />
<TextView
android:id="#+id/textView8"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:background="#color/buttonColor"
android:text="view"
android:textColor="#color/textMainColour"
app:layout_constraintBottom_toBottomOf="#+id/textView4"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="#+id/textView4"
app:layout_constraintTop_toTopOf="#+id/textView4" />
</androidx.constraintlayout.widget.ConstraintLayout>
You can nest multiple layouts (LinearLayout, RelativeLayout, CoordinatorLayout) to achieve what you want.
If I understand what you asked, you are probably looking for something like this:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:padding="16dp"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout
android:id="#+id/rl1"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ImageView
android:id="#+id/imgPartidasRecomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginRight="16dp"
android:layout_marginEnd="16dp"
android:src="#drawable/ic_launcher_foreground" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/rl2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toEndOf="#+id/rl1"
android:layout_toRightOf="#+id/rl1">
<TextView
android:id="#+id/tv_perfil_partidasJugadas"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginLeft="16dp"
android:background="#android:color/transparent"
android:text="Partidas"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_partidasJugadasNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginLeft="16dp"
android:layout_marginBottom="10dp"
android:layout_below="#id/tv_perfil_partidasJugadas"
android:layout_centerInParent="true"
android:text="0"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/rl3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toEndOf="#+id/rl2"
android:layout_toRightOf="#+id/rl2">
<TextView
android:id="#+id/tv_perfil_recomendaciones"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="60dp"
android:layout_marginLeft="60dp"
android:background="#android:color/transparent"
android:text="Recomendaciones"
android:textAppearance="#style/TextAppearance.AppCompat.Small"
android:textColor="#727272" />
<TextView
android:id="#+id/tv_recomendacionesNumber"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/tv_perfil_recomendaciones"
android:layout_alignParentBottom="true"
android:layout_marginStart="60dp"
android:layout_marginLeft="60dp"
android:layout_marginBottom="10dp"
android:text="0"
android:layout_centerInParent="true"
android:textAlignment="center"
android:textAppearance="#style/TextAppearance.AppCompat.Medium"
android:textColor="#212121"
android:textSize="20sp" />
</RelativeLayout>
</RelativeLayout>
I suggest you to use Constraint Layout to build better responsive layouts (easier).
I'm trying to align multiple TextView items in a CardView. I'm going to use this CardView in my RecyclerView to display data. But this doesn't work for all screen size. First I'm showing some static labels and then a CardView to show real data. Below is the code for my layout file:
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto">
<TextView
android:id="#+id/textView3"
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:background="#drawable/side_nav_bar"
android:text="Name"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView12"
android:layout_width="20dp"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginTop="16dp"
android:background="#drawable/side_nav_bar"
android:text="P"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintStart_toEndOf="#+id/textView3"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView13"
android:layout_width="25dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:text="W"
android:background="#drawable/side_nav_bar"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.073"
app:layout_constraintStart_toEndOf="#+id/textView12"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView14"
android:layout_width="20dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:text="L"
android:background="#drawable/side_nav_bar"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.084"
app:layout_constraintStart_toEndOf="#+id/textView13"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView15"
android:layout_width="20dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:text="D"
android:background="#drawable/side_nav_bar"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.112"
app:layout_constraintStart_toEndOf="#+id/textView14"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView16"
android:layout_width="35dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:background="#drawable/side_nav_bar"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.092"
app:layout_constraintStart_toEndOf="#+id/textView15"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="#+id/textView17"
android:layout_width="40dp"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:text="Pts"
android:background="#drawable/side_nav_bar"
android:textAlignment="center"
android:textColor="#fff"
android:textSize="24sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="#+id/textView16"
app:layout_constraintTop_toTopOf="parent" />
<android.support.v7.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="#id/textView3"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:layout_marginTop="10dp">
<TextView
android:layout_width="80dp"
android:layout_height="wrap_content"
android:text="Wisdom High"
android:textAlignment="center"
android:textSize="16dp"
android:id="#+id/table_team_name"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="12"
android:textSize="16dp"
android:textAlignment="center"
android:layout_marginLeft="95dp"
android:id="#+id/played"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:textSize="16dp"
android:textAlignment="center"
android:layout_marginLeft="145dp"
android:id="#+id/won"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="12"
android:textSize="16dp"
android:textAlignment="center"
android:layout_marginLeft="185dp"
android:id="#+id/lost"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:textSize="16dp"
android:textAlignment="center"
android:layout_marginLeft="230dp"
android:id="#+id/draw"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="+12"
android:textSize="16dp"
android:textAlignment="center"
android:layout_marginLeft="260dp"
android:id="#+id/gd"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="12"
android:textSize="16dp"
android:layout_marginLeft="310dp"
android:id="#+id/points"/>
</android.support.v7.widget.CardView>
It doesn't work for all screen sizes.
It is always preferred to use Relative Layout for better view alignment .
<android.support.v7.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="10dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#id/textView3">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:id="#+id/table_team_name"
android:layout_width="80dp"
android:layout_height="wrap_content"
android:text="Wisdom High"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/played"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="95dp"
android:text="12"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/won"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="145dp"
android:text="0"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/lost"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="185dp"
android:text="12"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/draw"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="230dp"
android:text="0"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/gd"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="260dp"
android:text="+12"
android:textAlignment="center"
android:textSize="16dp" />
<TextView
android:id="#+id/points"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="310dp"
android:text="12"
android:textSize="16dp" />
</RelativeLayout>
</android.support.v7.widget.CardView>
for multiple screens For Text Size and For Dimenions
Avoid using hard coded layout sizes.
Use RelativeLayout inside the CardView
prashant-luhar, you can use sth like this: (for every screen size with 'layout-weight' property)
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#888"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Name"
android:textAlignment="center" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P"
android:textAlignment="center" />
<TextView
android:layout_width="25dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.8"
android:orientation="horizontal">
<LinearLayout
android:id="#+id/ll1"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="A"
android:textAlignment="center"
android:textColor="#fff"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P1"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W1"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="B"
android:textAlignment="center"
android:textColor="#fff"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P2"
android:textAlignment="center"
android:textColor="#fff" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W2"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff"
/>
</LinearLayout>
<LinearLayout
android:id="#+id/ll3"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="C"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P3"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W3"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff"
/>
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P4"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W4"
android:textAlignment="center"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff"
/>
</LinearLayout>
<LinearLayout
android:id="#+id/ll5"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="E"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P5"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W5"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff"
/>
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="#+id/textView3"
android:layout_width="75dp"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="F"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="P6"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="W6"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="L"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="D"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="GD"
android:textAlignment="center"
android:textColor="#fff"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:text="Pts"
android:textAlignment="center"
android:textColor="#fff"
/>
</LinearLayout>
</LinearLayout>
I have a complicated Layout that created with constraintlayout and i need to scroll Vertically some part of it with scroll view and of Course this scroll view must include constraintlayout too,
Is any Body can help ?
I bring My code maybe it could help
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/colorPrimaryLight"
tools:context=".MainActivity"
tools:layout_editor_absoluteY="25dp">
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guideLineLeft"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.02676399" />
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guideLineRight"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.98053527" />
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guidelineTop"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.019151846" />
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guideLineH20to25Percent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_percent="0.20519836" />
<EditText
android:id="#+id/edit_city"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
android:background="#color/colorPrimaryLight"
android:lines="1"
android:maxLength="20"
android:maxLines="1"
android:minWidth="75dp"
android:paddingStart="4dp"
android:paddingLeft="4dp"
android:paddingTop="8dp"
android:paddingEnd="8dp"
android:paddingRight="8dp"
android:paddingBottom="8dp"
android:textAlignment="center"
android:textColor="#e1e1e1"
android:textSize="22sp"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="#+id/guideLineRight"
app:layout_constraintStart_toStartOf="#+id/guideLineLeft"
app:layout_constraintTop_toTopOf="#+id/guidelineTop" />
<ImageView
android:id="#+id/get_location_btn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:onClick="btn_clicked"
android:src="#drawable/ic_send2"
app:layout_constraintBottom_toBottomOf="#+id/edit_city"
app:layout_constraintEnd_toEndOf="#+id/edit_city"
app:layout_constraintStart_toEndOf="#+id/edit_city"
app:layout_constraintTop_toTopOf="#+id/edit_city" />
<TextView
android:id="#+id/current_weather_condition_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:minWidth="100dp"
android:textAlignment="center"
android:textColor="#color/colorText"
android:textSize="18sp"
app:layout_constraintEnd_toEndOf="#+id/edit_city"
app:layout_constraintStart_toStartOf="#+id/edit_city"
app:layout_constraintTop_toBottomOf="#+id/edit_city" />
<TextView
android:id="#+id/current_weather_temp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:textColor="#fff"
android:textSize="32sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="#+id/current_weather_condition_view"
app:layout_constraintStart_toStartOf="#+id/current_weather_condition_view"
app:layout_constraintTop_toBottomOf="#+id/current_weather_condition_view" />
<TextView
android:id="#+id/todayNameView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="24dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintStart_toStartOf="#+id/guideLineLeft"
app:layout_constraintTop_toBottomOf="#+id/guideLineH20to25Percent" />
<TextView
android:id="#+id/todayView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:text="Today"
android:textColor="#fff"
android:textSize="16sp"
android:textStyle="bold"
app:layout_constraintBaseline_toBaselineOf="#+id/todayNameView"
app:layout_constraintStart_toEndOf="#+id/todayNameView" />
<TextView
android:id="#+id/todayMinTemperature"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintBottom_toBottomOf="#+id/todayMaxTemperature"
app:layout_constraintEnd_toStartOf="#+id/guideLineRight"
app:layout_constraintTop_toTopOf="#+id/todayMaxTemperature" />
<TextView
android:id="#+id/todayMaxTemperature"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="24dp"
android:layout_marginEnd="8dp"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toStartOf="#+id/guideLineRight"
app:layout_constraintTop_toBottomOf="#+id/guideLineH20to25Percent" />
<View
android:id="#+id/view1"
android:layout_width="0dp"
android:layout_height="1dp"
android:layout_marginTop="8dp"
android:background="#FFF"
android:textAlignment="center"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/todayNameView" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:scrollbars="none"
app:layout_constraintEnd_toEndOf="#+id/guideLineRight"
app:layout_constraintStart_toStartOf="#+id/guideLineLeft"
app:layout_constraintTop_toBottomOf="#+id/view1">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<androidx.constraintlayout.widget.Guideline
android:id="#+id/guidelineMiddleH"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.5" />
<androidx.recyclerview.widget.RecyclerView
android:id="#+id/recycler_view1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="4dp"
android:minHeight="100dp"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<View
android:id="#+id/view2"
android:layout_width="0dp"
android:layout_height="1dp"
android:background="#fff"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/recycler_view1" />
<ImageView
android:id="#+id/imgIcon1"
android:layout_width="35dp"
android:layout_height="35dp"
android:layout_marginTop="8dp"
app:layout_constraintEnd_toStartOf="#+id/guidelineMiddleH"
app:layout_constraintStart_toStartOf="#+id/guidelineMiddleH"
app:layout_constraintTop_toBottomOf="#+id/view2" />
<ImageView
android:id="#+id/imgIcon2"
android:layout_width="35dp"
android:layout_height="35dp"
app:layout_constraintEnd_toEndOf="#+id/imgIcon1"
app:layout_constraintStart_toStartOf="#+id/imgIcon1"
app:layout_constraintTop_toBottomOf="#+id/imgIcon1" />
<ImageView
android:id="#+id/imgIcon3"
android:layout_width="35dp"
android:layout_height="35dp"
app:layout_constraintEnd_toEndOf="#+id/imgIcon2"
app:layout_constraintStart_toStartOf="#+id/imgIcon2"
app:layout_constraintTop_toBottomOf="#+id/imgIcon2" />
<ImageView
android:id="#+id/imgIcon4"
android:layout_width="35dp"
android:layout_height="35dp"
app:layout_constraintEnd_toEndOf="#+id/imgIcon3"
app:layout_constraintStart_toStartOf="#+id/imgIcon3"
app:layout_constraintTop_toBottomOf="#+id/imgIcon3" />
<ImageView
android:id="#+id/imgIcon5"
android:layout_width="35dp"
android:layout_height="35dp"
app:layout_constraintEnd_toEndOf="#+id/imgIcon4"
app:layout_constraintStart_toStartOf="#+id/imgIcon4"
app:layout_constraintTop_toBottomOf="#+id/imgIcon4" />
<TextView
android:id="#+id/firstDay"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon1" />
<TextView
android:id="#+id/secondDay"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon2"
app:layout_constraintVertical_bias="0.51" />
<TextView
android:id="#+id/thirdDay"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon3" />
<TextView
android:id="#+id/fourthDay"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon4" />
<TextView
android:id="#+id/fivthDay"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon5"/>
<TextView
android:id="#+id/maxTemp1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textAlignment="gravity"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon1" />
<TextView
android:id="#+id/maxTemp2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon2" />
<TextView
android:id="#+id/maxTemp3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon3" />
<TextView
android:id="#+id/maxTemp4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon4" />
<TextView
android:id="#+id/maxTemp5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="40dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/imgIcon5" />
<TextView
android:id="#+id/minTemp1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:textAlignment="gravity"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/maxTemp1" />
<TextView
android:id="#+id/minTemp2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/maxTemp2" />
<TextView
android:id="#+id/minTemp3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/maxTemp3" />
<TextView
android:id="#+id/minTemp4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/maxTemp4" />
<TextView
android:id="#+id/minTemp5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:textColor="#c5c5c5"
android:textSize="18sp"
android:textStyle="normal|bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="#+id/maxTemp5" />
<View
android:id="#+id/view3"
android:layout_width="0dp"
android:layout_height="1dp"
android:layout_marginTop="8dp"
android:background="#fff"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/imgIcon5" />
<TextView
android:id="#+id/wind_name_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="16dp"
android:text="Wind"
android:textColor="#color/colorPrimaryDark"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/view3" />
<TextView
android:id="#+id/currentSpeed"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/wind_name_view" />
<TextView
android:id="#+id/pressure_name_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:text="PRESSURE"
android:textColor="#color/colorPrimaryDark"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#+id/guidelineMiddleH"
app:layout_constraintTop_toBottomOf="#+id/currentFeelTemperature" />
<TextView
android:id="#+id/currentPressure"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#+id/pressure_name_view"
app:layout_constraintTop_toBottomOf="#+id/pressure_name_view" />
<TextView
android:id="#+id/feelLike_name_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:text="FEELS LIKE"
android:textColor="#color/colorPrimaryDark"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#+id/guidelineMiddleH"
app:layout_constraintTop_toBottomOf="#+id/view3" />
<TextView
android:id="#+id/currentFeelTemperature"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="#+id/feelLike_name_view"
app:layout_constraintTop_toBottomOf="#+id/feelLike_name_view" />
<TextView
android:id="#+id/humidity_name_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="16dp"
android:text="HUMIDITY"
android:textColor="#color/colorPrimaryDark"
android:textSize="14sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/currentSpeed" />
<TextView
android:id="#+id/currentHumidity"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:textColor="#fff"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/humidity_name_view" />
</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>
</androidx.constraintlayout.widget.ConstraintLayout>
Try adding android:fillViewport="true" to the ScrollView.
Don't forget that If you constraint some view's bottom to constraint layout's bottom.Scrollview could not scroll.
app:layout_constraintBottom_toBottomOf=“parent”
It seems that it is working, I don't know what dependency you were working with but in this one
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
Is working, this is what I did
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<View
android:id="#+id/view"
android:layout_width="377dp"
android:layout_height="2dp"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_alignParentBottom="true"
android:background="#000000"
app:layout_constraintBottom_toTopOf="#+id/linearLayout2"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.64" />
<LinearLayout
android:id="#+id/linearLayout2"
android:layout_width="176dp"
android:layout_height="268dp"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true"
android:layout_marginStart="16dp"
android:layout_marginLeft="16dp"
android:layout_marginBottom="40dp"
android:orientation="vertical"
app:layout_constraintBottom_toTopOf="#+id/textView17"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="1.0">
<TextView
android:id="#+id/textView8"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Account #"
android:textColor="#000000"
android:textSize="18sp" />
<!-- <TextView-->
<!-- android:id="#+id/textView9"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="wrap_content"-->
<!-- android:layout_marginTop="#dimen/lintext"-->
<!-- android:text="Company Name "-->
<!-- android:textColor="#000000"-->
<!-- android:textSize="18sp" />-->
<TextView
android:id="#+id/textView10"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Phone"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Address"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView5"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Serial number"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView6"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Product name "
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView7"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Brand"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView13"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Subject"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="#+id/textView11"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="#dimen/lintext"
android:text="Problem Details "
android:textColor="#000000"
android:textSize="18sp" />
</LinearLayout>
<LinearLayout
android:id="#+id/linearLayout3"
android:layout_width="187dp"
android:layout_height="263dp"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_marginTop="32dp"
android:layout_marginEnd="16dp"
android:layout_marginRight="16dp"
android:orientation="vertical"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="1.0"
app:layout_constraintStart_toEndOf="#+id/linearLayout2"
app:layout_constraintTop_toTopOf="parent">
<TextView
android:id="#+id/from_name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Ahmed hassen" />
<TextView
android:id="#+id/name_product"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="12dp"
android:text="26 Horrya st ,helioplis 11341" />
<TextView
android:id="#+id/num_ser"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="+201111414141" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="CZ3351x4BW" />
<TextView
android:id="#+id/textView12"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="Hp SL230 Gen8 Rht half Svr" />
<TextView
android:id="#+id/textView14"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="Hp" />
<TextView
android:id="#+id/textView15"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="Broken Screen" />
<TextView
android:id="#+id/textView16"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_marginTop="12dp"
android:text="Broken Screen and we gonna replace it " />
</LinearLayout>
<ImageView
android:id="#+id/imageView9"
android:layout_width="377dp"
android:layout_height="70dp"
android:layout_marginTop="40dp"
android:src="#color/colorPrimary"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.328"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/editText4" />
<EditText
android:id="#+id/editText3"
android:layout_width="83dp"
android:layout_height="48dp"
android:layout_marginTop="60dp"
android:background="#drawable/style_et_border"
android:ems="10"
android:inputType="textPersonName"
android:text=" 500"
android:textColor="#FFFFFF"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.536"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/editText4" />
<TextView
android:id="#+id/textView21"
android:layout_width="134dp"
android:layout_height="32dp"
android:layout_marginEnd="12dp"
android:layout_marginRight="12dp"
android:text="Estimated Labor"
android:textColor="#FFFFFF"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintBottom_toTopOf="#+id/editText3"
app:layout_constraintEnd_toStartOf="#+id/editText3"
app:layout_constraintTop_toTopOf="#+id/imageView9"
app:layout_constraintVertical_bias="0.0" />
<TextView
android:id="#+id/textView22"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="EGP"
android:textColor="#FFFFFF"
android:textSize="18sp"
app:layout_constraintBottom_toBottomOf="#+id/imageView9"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.196"
app:layout_constraintStart_toEndOf="#+id/editText3"
app:layout_constraintTop_toTopOf="#+id/imageView9"
app:layout_constraintVertical_bias="0.695" />
<View
android:id="#+id/ll"
android:layout_width="377dp"
android:layout_height="3dp"
android:layout_alignParentStart="true"
android:layout_alignParentLeft="true"
android:layout_alignParentBottom="true"
android:layout_marginTop="15dp"
android:background="#000000"
app:layout_constraintBottom_toBottomOf="#+id/linearLayout2"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/linearLayout3" />
<TextView
android:id="#+id/editText"
android:layout_width="376dp"
android:layout_height="93dp"
android:layout_marginTop="72dp"
android:layout_weight="1"
android:background="#drawable/style_et_border"
android:ems="10"
android:text="A dying or cracked display doesn't mean your laptop is a paperweight. For most laptops, a screen replacement takes"
android:textSize="18sp"
app:layout_constraintBottom_toBottomOf="#+id/textView17"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.507"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/linearLayout3"
app:layout_constraintVertical_bias="0.0" />
<TextView
android:id="#+id/textView17"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginLeft="20dp"
android:layout_marginBottom="8dp"
android:text="Problem Found "
android:textColor="#000000"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintBottom_toTopOf="#+id/editText"
app:layout_constraintStart_toStartOf="parent" />
<TextView
android:id="#+id/textView18"
android:layout_width="219dp"
android:layout_height="29dp"
android:layout_marginTop="64dp"
android:text="Spare Parts Selected"
android:textColor="#000000"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.074"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/textView19" />
<TextView
android:id="#+id/editText4"
android:layout_width="412dp"
android:layout_height="49dp"
android:layout_marginTop="8dp"
android:background="#drawable/style_et_border"
android:ems="10"
android:text=" ** Kingston Kvr16N11/8 - 8Gb Ddr3 Pc3-12800 1600Mhz Non-Ecc Cl11 Desktop Memory "
android:textSize="18sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="1.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/editText5" />
<TextView
android:id="#+id/editText5"
android:layout_width="412dp"
android:layout_height="49dp"
android:background="#drawable/style_et_border"
android:ems="10"
android:text=" ** Kingston Kvr16N11/8 - 8Gb Ddr3 Pc3-12800 1600Mhz Non-Ecc Cl11 Desktop Memory "
android:textSize="18sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/textView18" />
<TextView
android:id="#+id/textView19"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="36dp"
android:text="Estimated time"
android:textColor="#000000"
android:textSize="18sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.085"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/editText" />
<TextView
android:id="#+id/editText2"
android:layout_width="134dp"
android:layout_height="30dp"
android:layout_marginTop="36dp"
android:background="#drawable/style_et_border"
android:ems="10"
android:text=" 6 Hours"
android:textColor="#000000"
android:textSize="18sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.224"
app:layout_constraintStart_toEndOf="#+id/textView19"
app:layout_constraintTop_toBottomOf="#+id/editText" />
<in.shadowfax.proswipebutton.ProSwipeButton
android:id="#+id/awesome_btn"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
app:bg_color="#android:color/holo_blue_dark"
app:btn_text="Close Your Ticket"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/button"
app:layout_constraintVertical_bias="0.027" />
<Button
android:id="#+id/button"
android:layout_width="230dp"
android:layout_height="45dp"
android:layout_marginTop="28dp"
android:background="#drawable/style_et_border"
android:onClick="goSignature"
android:text="put your signature here"
android:textAllCaps="false"
android:textSize="20sp"
android:textStyle="bold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.496"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="#+id/editText3" />
</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.constraint.ConstraintLayout
android:id="#+id/constraintLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
</android.support.constraint.ConstraintLayout>
</ScrollView>