Here is the image for which it now looks. I want the float button to be right at the bottom of the screen. Here I am trying to do this. So here is the activity_main file:
<?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:fitsSystemWindows="true"
tools:context="com.example.jaden.finances.MainActivity">
<android.support.v7.widget.Toolbar
android:id="@+id/appBarLayout"
android:layout_width="360dp"
android:layout_height="81dp"
android:background="?attr/colorPrimary"
app:popupTheme="@style/AppTheme.PopupOverlay"
tools:layout_editor_absoluteY="0dp"
tools:layout_editor_absoluteX="0dp" />
<android.support.design.widget.FloatingActionButton
android:id="@+id/fab"
android:layout_width="40dp"
android:layout_height="40dp"
app:srcCompat="@android:drawable/ic_dialog_email"
tools:layout_editor_absoluteY="0dp"
tools:layout_editor_absoluteX="0dp" />
<EditText
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:inputType="text"
android:text="Name"
android:ems="10"
android:id="@+id/editText"
android:hint="@string/edit_message"
tools:layout_editor_absoluteY="83dp"
tools:layout_editor_absoluteX="16dp" />
<Button
android:text="@string/button_send"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/button3"
android:onClick="sendMessage"
tools:layout_editor_absoluteX="249dp"
tools:layout_editor_absoluteY="81dp" />
<ScrollView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:layout_editor_absoluteY="126dp"
tools:layout_editor_absoluteX="8dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:id="@+id/options">
</LinearLayout>
</ScrollView>
</android.support.constraint.ConstraintLayout>
I'm not sure what I'm doing wrong. When I go to the graphic design editor and click and drag the edges to create a new constraint, it will not click on the edges of the screen. A Google search does not produce anything.
source
share