make the input boxes look prettier, for real this time

This commit is contained in:
Kay Faraday 2023-06-05 22:05:54 +00:00
parent 94c45c47bb
commit 6925902d1b
3 changed files with 14 additions and 8 deletions

View File

@ -12,10 +12,10 @@
<com.google.android.material.textfield.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:id="@+id/subtotal_text_input_layout" style="@style/text_input_style"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="0dp"
android:hint="Subtotal"> android:hint="Subtotal">
<com.google.android.material.textfield.TextInputEditText <com.google.android.material.textfield.TextInputEditText
@ -28,11 +28,10 @@
<com.google.android.material.textfield.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:id="@+id/tax_input_layout"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="Tax" android:hint="Tax"
style="@style/text_input_style"
> >
<com.google.android.material.textfield.TextInputEditText <com.google.android.material.textfield.TextInputEditText
android:id="@+id/tax_edit" android:id="@+id/tax_edit"
@ -43,8 +42,7 @@
</com.google.android.material.textfield.TextInputLayout> </com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout <com.google.android.material.textfield.TextInputLayout
android:id="@+id/gratuity_input_layout" style="@style/text_input_style"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="Gratuity" android:hint="Gratuity"
@ -62,6 +60,7 @@
<Button <Button
android:id="@+id/calculate_button" android:id="@+id/calculate_button"
android:layout_marginTop="@dimen/layout_margin"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
@ -70,7 +69,7 @@
<TextView <TextView
android:id="@+id/results_text" android:id="@+id/results_text"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox" style="@style/text_input_style"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:textSize="24sp" android:textSize="24sp"

View File

@ -3,4 +3,4 @@
<dimen name="padding">16dp</dimen> <dimen name="padding">16dp</dimen>
<dimen name="small_padding">8dp</dimen> <dimen name="small_padding">8dp</dimen>
<dimen name="layout_margin">16dp</dimen> <dimen name="layout_margin">16dp</dimen>
</resources> </resources>

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android">
<style name="text_input_style" parent="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
<item name="android:layout_marginTop">@dimen/layout_margin</item>
<item name="android:paddingTop">@dimen/small_padding</item>
</style>
</resources>