AndroidAPS/app/src/main/res/layout/food_item.xml

113 lines
3.9 KiB
XML
Raw Normal View History

2017-10-17 20:55:23 +02:00
<?xml version="1.0" encoding="utf-8"?>
2019-05-16 13:57:37 +02:00
<androidx.cardview.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
2017-10-17 20:55:23 +02:00
xmlns:card_view="http://schemas.android.com/apk/res-auto"
2021-03-19 18:49:34 +01:00
xmlns:tools="http://schemas.android.com/tools"
2017-10-17 20:55:23 +02:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
2021-03-19 18:49:34 +01:00
card_view:cardBackgroundColor="?android:colorBackground">
2017-10-17 20:55:23 +02:00
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="horizontal">
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/name"
android:layout_width="0dp"
2017-10-17 20:55:23 +02:00
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="Name"
2021-03-19 18:49:34 +01:00
android:textStyle="bold"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/portion"
2017-10-17 20:55:23 +02:00
android:layout_width="60dp"
android:layout_height="wrap_content"
android:gravity="end"
2021-03-19 18:49:34 +01:00
android:text="Portion"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/carbs"
2017-10-17 20:55:23 +02:00
android:layout_width="50dp"
android:layout_height="wrap_content"
android:gravity="end"
2021-03-19 18:49:34 +01:00
android:text="Carbs"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
2021-01-25 11:35:36 +01:00
android:layout_height="0dp"
2017-10-17 20:55:23 +02:00
android:layout_weight="1"
android:gravity="end"
android:orientation="horizontal">
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/fat"
2017-10-17 20:55:23 +02:00
android:layout_width="70dp"
android:layout_height="wrap_content"
android:gravity="end"
2021-03-19 18:49:34 +01:00
android:text="Fat"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/protein"
2017-10-17 20:55:23 +02:00
android:layout_width="70dp"
android:layout_height="wrap_content"
android:gravity="end"
2021-03-19 18:49:34 +01:00
android:text="Protein"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/energy"
2017-10-17 20:55:23 +02:00
android:layout_width="70dp"
android:layout_height="wrap_content"
android:gravity="end"
2021-03-19 18:49:34 +01:00
android:text="Energy"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
android:id="@+id/ns_sign"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:width="30dp"
android:text="NS"
android:textAlignment="viewEnd"
2021-03-19 18:49:34 +01:00
android:textColor="@color/colorSetTempButton"
tools:ignore="HardcodedText" />
2017-10-17 20:55:23 +02:00
<TextView
2021-01-25 11:35:36 +01:00
android:id="@+id/remove"
2017-10-17 20:55:23 +02:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingEnd="5dp"
android:paddingStart="10dp"
2021-02-22 18:04:30 +01:00
android:text="@string/remove_button"
2017-10-17 20:55:23 +02:00
android:textAlignment="viewEnd"
android:textColor="@android:color/holo_orange_light" />
</LinearLayout>
2021-03-19 18:49:34 +01:00
<View
android:layout_width="fill_parent"
android:layout_height="2dip"
android:layout_marginBottom="5dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:layout_marginTop="5dp"
android:background="@color/list_delimiter" />
2017-10-17 20:55:23 +02:00
</LinearLayout>
2019-05-16 13:57:37 +02:00
</androidx.cardview.widget.CardView>