Cart page design in android.


<?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"
    app:layout_behavior="@string/appbar_scrolling_view_behavior"
    tools:context=".Cart"
    tools:showIn="@layout/activity_cart">
    <LinearLayout
        android:id="@+id/activity_cart_list"
        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"
        android:orientation="vertical"
        android:weightSum="10"
        tools:context=".Cart">

        <LinearLayout
            android:id="@+id/layout_items"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:layout_weight="9.5"
            android:paddingLeft="@dimen/activity_horizontal_margin"
            android:paddingTop="@dimen/activity_vertical_margin"
            android:paddingRight="@dimen/activity_horizontal_margin"
            android:visibility="visible">

            <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="vertical"
                android:paddingBottom="@dimen/margin_medium">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="horizontal"
                    android:weightSum="3">

                    <com.facebook.drawee.view.SimpleDraweeView xmlns:fresco="http://schemas.android.com/apk/res-auto"
                        android:id="@+id/image_cartlist"
                        android:layout_width="100dp"
                        android:layout_height="80dp"
                        android:layout_gravity="center_vertical"
                        android:layout_weight="1"
                        fresco:placeholderImage="@color/stay_color" />

                    <LinearLayout
                        android:id="@+id/layout_item_desc"
                        android:layout_width="fill_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginLeft="@dimen/activity_horizontal_margin"
                        android:layout_weight="2"
                        android:orientation="vertical">

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="Denim Shirt"
                            android:textSize="@dimen/text_size_small"
                            android:textStyle="bold" />

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="Slim fit, cotton"
                            android:textSize="@dimen/text_size_small" />

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_marginTop="@dimen/margin_small"
                            android:text="Rs. 8,999"
                            android:textColor="#4CAF50"
                            android:textSize="@dimen/text_size_xmedium" />

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="Delivery charge: FREE"
                            android:textSize="@dimen/text_size_small" />

                        <LinearLayout
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:layout_marginTop="@dimen/margin_medium"
                            android:orientation="horizontal">

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="Qty: 1"
                                android:textSize="@dimen/text_size_small" />

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_marginLeft="@dimen/margin_medium"
                                android:text="Size: 41"
                                android:textSize="@dimen/text_size_small" />
                        </LinearLayout>
                    </LinearLayout>
                </LinearLayout>

                <View
                    android:layout_width="match_parent"
                    android:layout_height="@dimen/view_width_small"
                    android:layout_marginTop="@dimen/margin_medium"
                    android:background="@color/grey_light" />

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="30dp"
                    android:layout_marginTop="8dp"
                    android:orientation="horizontal"
                    android:weightSum="2">

                    <LinearLayout
                        android:id="@+id/layout_action1"
                        android:layout_width="0dp"
                        android:layout_height="match_parent"
                        android:layout_weight="1"
                        android:gravity="center"
                        android:orientation="horizontal"
                        android:weightSum="2">

                        <ImageView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:src="@drawable/ic_clear_black_18dp" />

                        <TextView
                            android:id="@+id/text_action1"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_marginLeft="8dp"
                            android:layout_weight="1"
                            android:gravity="left"
                            android:text="Remove"
                            android:textColor="@color/gen_black"
                            android:textSize="12dp" />
                    </LinearLayout>

                    <View
                        android:layout_width="@dimen/view_width_small"
                        android:layout_height="match_parent"
                        android:background="@color/grey_light" />

                    <LinearLayout
                        android:id="@+id/layout_action2"
                        android:layout_width="0dp"
                        android:layout_height="match_parent"
                        android:layout_weight="1"
                        android:gravity="center"
                        android:orientation="horizontal"
                        android:weightSum="2">

                        <ImageView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:src="@drawable/ic_mode_edit_black_18dp" />

                        <TextView
                            android:id="@+id/text_action2"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_marginLeft="8dp"
                            android:layout_weight="1"
                            android:gravity="left"
                            android:text="Edit"
                            android:textColor="@color/gen_black"
                            android:textSize="12dp" />
                    </LinearLayout>

                </LinearLayout>

                <View
                    android:layout_width="match_parent"
                    android:layout_height="@dimen/view_width_small"
                    android:layout_marginTop="8dp"
                    android:layout_marginBottom="8dp"
                    android:background="@color/grey_light" />
            </LinearLayout>


        </LinearLayout>
        <LinearLayout android:id="@+id/layout_payment"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_weight="0.5"
            android:orientation="horizontal"
            android:weightSum="2"
            android:elevation="30dp"
            android:background="@color/gen_black"
            android:visibility="visible">
            <TextView android:id="@+id/text_action_bottom1"
                android:layout_width="wrap_content"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:background="@color/gen_white"
                android:text="Rs 8,750"
                android:textSize="14dp"
                android:textColor="#fff"
                android:textStyle="bold"
                android:gravity="center"/>

            <TextView android:id="@+id/text_action_bottom2"
                android:layout_width="wrap_content"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:background="@color/colorPrimary"
                android:text="PAYMENT"
                android:textSize="14dp"
                android:textColor="#fff"
                android:textStyle="bold"
                android:gravity="center"/>
        </LinearLayout>
        <!--<include android:id="@+id/layout_cart_empty"-->
            <!--layout="@layout/empty_message_layout_action"-->
            <!--android:layout_width="match_parent"-->
            <!--android:layout_height="match_parent"/>-->
    </LinearLayout>

</androidx.constraintlayout.widget.ConstraintLayout>









Popular posts from this blog

Simple Sign up design. Android.

Set Date on jDateChooser and retrieve record from database.