Commit 984ed02f by Paktalin

New word fields are now fixed at the top

parent 28dea025
<shape android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="@color/sheet_color"/>
<corners
android:bottomRightRadius="@dimen/corner_radius"
android:bottomLeftRadius="@dimen/corner_radius" />
</shape>
\ No newline at end of file
<shape android:shape="rectangle" <shape android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android"> xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="#FAFAFA"/> <solid android:color="@color/sheet_color"/>
<corners android:radius="5dp"/> <corners android:topLeftRadius="@dimen/corner_radius"
android:topRightRadius="@dimen/corner_radius"/>
</shape> </shape>
\ No newline at end of file
...@@ -5,7 +5,8 @@ ...@@ -5,7 +5,8 @@
android:id="@+id/drawerLayout" android:id="@+id/drawerLayout"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
tools:openDrawer="start"> tools:openDrawer="start"
android:background="#66330E">
<FrameLayout <FrameLayout
android:layout_width="match_parent" android:layout_width="match_parent"
......
...@@ -3,34 +3,60 @@ ...@@ -3,34 +3,60 @@
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent">
android:background="#66330E">
<FrameLayout
android:id="@+id/frameLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="@dimen/small_margin"
android:layout_marginLeft="@dimen/small_margin"
android:layout_marginRight="@dimen/small_margin"
android:layout_marginStart="@dimen/small_margin"
android:layout_marginTop="@dimen/small_margin"
android:paddingStart="@dimen/small_padding"
android:paddingLeft="@dimen/small_padding"
android:paddingEnd="@dimen/small_padding"
android:paddingRight="@dimen/small_padding"
android:paddingTop="@dimen/small_padding"
android:background="@drawable/sheet_top"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<fragment
android:id="@+id/fragmentNewWord"
android:name="com.paktalin.vocabularynotebook.ui.AddWordFragment"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</FrameLayout>
<ScrollView <ScrollView
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="0dp"
android:layout_marginBottom="@dimen/small_margin"
android:layout_marginEnd="@dimen/small_margin"
android:layout_marginLeft="@dimen/small_margin"
android:layout_marginRight="@dimen/small_margin"
android:layout_marginStart="@dimen/small_margin"
android:scrollbars="vertical" android:scrollbars="vertical"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toBottomOf="@+id/frameLayout"
android:layout_margin="8dp"> app:layout_constraintVertical_bias="0.0">
<LinearLayout <LinearLayout
android:id="@+id/fragment_container" android:id="@+id/fragment_container"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="8dp" android:background="@drawable/sheet_bottom"
android:background="@drawable/sheet_background" android:orientation="vertical"
android:orientation="vertical"> android:paddingStart="@dimen/small_padding"
android:paddingLeft="@dimen/small_padding"
<fragment android:paddingEnd="@dimen/small_padding"
android:id="@+id/fragmentNewWord" android:paddingRight="@dimen/small_padding"
android:name="com.paktalin.vocabularynotebook.ui.AddWordFragment" android:paddingBottom="@dimen/small_padding">
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp" />
</LinearLayout> </LinearLayout>
</ScrollView> </ScrollView>
...@@ -48,13 +74,10 @@ ...@@ -48,13 +74,10 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="end" android:layout_gravity="end"
android:layout_marginBottom="8dp" android:layout_margin="@dimen/small_margin"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:background="@android:color/transparent" android:background="@android:color/transparent"
app:srcCompat="@drawable/ic_done_icon" app:srcCompat="@drawable/ic_done_icon"
tools:ignore="ContentDescription" /> tools:ignore="ContentDescription" />
</FrameLayout> </FrameLayout>
</android.support.constraint.ConstraintLayout> </android.support.constraint.ConstraintLayout>
\ No newline at end of file
...@@ -3,4 +3,5 @@ ...@@ -3,4 +3,5 @@
<color name="colorPrimary">#3F51B5</color> <color name="colorPrimary">#3F51B5</color>
<color name="colorPrimaryDark">#303F9F</color> <color name="colorPrimaryDark">#303F9F</color>
<color name="colorAccent">#FF4081</color> <color name="colorAccent">#FF4081</color>
<color name="sheet_color">#FAFAFA</color>
</resources> </resources>
...@@ -2,4 +2,8 @@ ...@@ -2,4 +2,8 @@
<!-- Default screen margins, per the Android Design guidelines. --> <!-- Default screen margins, per the Android Design guidelines. -->
<dimen name="activity_horizontal_margin">16dp</dimen> <dimen name="activity_horizontal_margin">16dp</dimen>
<dimen name="activity_vertical_margin">16dp</dimen> <dimen name="activity_vertical_margin">16dp</dimen>
<dimen name="corner_radius">5dp</dimen>
<dimen name="zero_corner_radius">0dp</dimen>
<dimen name="small_margin">8dp</dimen>
<dimen name="small_padding">8dp</dimen>
</resources> </resources>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment