android fragment replace fiil_parent with frame layout - android

according to picture when i replace my fragment into FrameLayout the the size is not fit. for example my button in page is under the main layout object
activity_main layout code
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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:id="#+id/activity_main"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/colorPrimary"
android:orientation="vertical"
tools:context="com.teskaco.bbpos.Activities.MainActivities.MainActivity">
<com.alirezaafkar.toolbar.Toolbar
android:id="#+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#color/colorPrimary"
android:paddingTop="#dimen/app_bar_top_padding"
app:direction="rtl"
app:font="#string/font_path"
app:navigationIcon="#drawable/m_e_n_u"
app:optionsMenu="#menu/main_menu">
<com.teskaco.bbpos.CustumView.CustomTextView
android:id="#+id/main_title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="#string/psp_name"
android:textColor="#color/colorControlNormal"
android:textSize="#dimen/small_text_size" />
</com.alirezaafkar.toolbar.Toolbar>
<FrameLayout
android:id="#+id/main_fragment"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1" />
<include
android:id="#+id/buttonPanel"
layout="#layout/main_top_bar" />
</LinearLayout>
my fragment layout xml code
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:id="#+id/fragment_pay"
tools:context="com.teskaco.bbpos.Activities.MainActivities.PayBillFragment">
<com.teskaco.bbpos.CustumView.CustomButton
android:id="#+id/send_button"
style="#style/LightRaiseColorButtonRippleStyle"
android:layout_width="#dimen/_300sdp"
android:layout_height="#dimen/button_height"
android:layout_gravity="center"
android:layout_marginTop="#dimen/_4sdp"
android:gravity="center"
android:text="#string/send_button"
android:textColor="#color/disable_button"
android:textSize="#dimen/button_text_size" />
<LinearLayout
android:orientation="vertical"
android:gravity="center|top"
android:layout_width="match_parent"
android:layout_weight="1"
android:layout_height="match_parent"
android:layout_marginTop="#dimen/_6sdp"
android:background="#color/white">
<RelativeLayout
android:id="#+id/skech_layout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_4sdp"
android:background="#color/white">
<ImageView
android:id="#+id/skech_image"
android:layout_width="#dimen/_90sdp"
android:layout_height="#dimen/_101sdp"
android:layout_centerHorizontal="true"
android:src="#drawable/ghabz" />
<com.teskaco.bbpos.CustumView.CustomTextView
android:id="#+id/ghabz_textview"
android:layout_width="#dimen/_250sdp"
android:layout_height="wrap_content"
android:layout_below="#+id/skech_image"
android:layout_centerHorizontal="true"
android:layout_marginTop="#dimen/_21sdp"
android:gravity="center"
android:text="#string/bill_text"
android:textSize="#dimen/mediume_text_size" />
</RelativeLayout>
<LinearLayout
android:id="#+id/name_layout"
android:layout_width="#dimen/_250sdp"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_8sdp"
android:background="#drawable/raduis_bg_edit_text"
android:orientation="horizontal">
<com.teskaco.bbpos.CustumView.CustomTextInputLayout
android:id="#+id/shenase_text_input_layout"
android:layout_width="#dimen/_210sdp"
android:layout_height="wrap_content"
android:layout_margin="#dimen/_5sdp"
android:theme="#style/TextLabel">
<com.teskaco.bbpos.CustumView.CustomEditText
android:id="#+id/id_bill"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginLeft="#dimen/_6sdp"
android:layout_marginRight="#dimen/_6sdp"
android:layout_marginTop="#dimen/_4sdp"
android:background="#null"
android:gravity="right"
android:hint="#string/id_Bill_text"
android:inputType="number"
android:paddingBottom="#dimen/_4sdp"
android:textColor="#color/green_blue"
android:textSize="#dimen/defult_text_size" />
</com.teskaco.bbpos.CustumView.CustomTextInputLayout>
<android.support.v7.widget.AppCompatImageView
android:layout_width="#dimen/_16sdp"
android:layout_height="#dimen/_12sdp"
android:layout_gravity="center"
android:layout_marginLeft="#dimen/_5sdp"
android:background="#drawable/user_id" />
</LinearLayout>
<LinearLayout
android:id="#+id/name_layout1"
android:layout_width="#dimen/_250sdp"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_8sdp"
android:background="#drawable/raduis_bg_edit_text"
android:orientation="horizontal">
<com.teskaco.bbpos.CustumView.CustomTextInputLayout
android:id="#+id/payment_text_input_layout"
android:layout_width="#dimen/_210sdp"
android:layout_height="wrap_content"
android:layout_margin="#dimen/_5sdp"
android:theme="#style/TextLabel">
<com.teskaco.bbpos.CustumView.CustomEditText
android:id="#+id/id_payment"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginLeft="#dimen/_6sdp"
android:layout_marginRight="#dimen/_6sdp"
android:layout_marginTop="#dimen/_4sdp"
android:background="#null"
android:gravity="right"
android:hint="#string/id_payment_text"
android:inputType="number"
android:paddingBottom="#dimen/_4sdp"
android:textColor="#color/green_blue"
android:textSize="#dimen/defult_text_size" />
</com.teskaco.bbpos.CustumView.CustomTextInputLayout>
<android.support.v7.widget.AppCompatImageView
android:layout_width="#dimen/_16sdp"
android:layout_height="#dimen/_12sdp"
android:layout_gravity="center"
android:layout_marginLeft="#dimen/_5sdp"
android:background="#drawable/user_id" />
</LinearLayout>
<com.teskaco.bbpos.CustumView.CustomButton
android:id="#+id/barcode_reader"
style="#style/GrayRaiseColorButtonRippleStyle"
android:layout_width="#dimen/_250sdp"
android:layout_height="#dimen/button_height"
android:layout_gravity="center"
android:layout_marginTop="#dimen/_24sdp"
android:gravity="center"
android:text="#string/barcode_reader_text"
android:textColor="#color/disable_button"
android:textSize="#dimen/button_text_size" />
</LinearLayout>
</LinearLayout>
replace code
fragmentManager = getSupportFragmentManager();
fragmentManager.beginTransaction().replace(R.id.main_fragment, PayBillFragment.newInstance()).addToBackStack("PayBill").commit();

You have to use Parent Layout as RelativeLayout and use RelativeLayout property.
<com.alirezaafkar.toolbar.Toolbar
android:id="#+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#color/colorPrimary"
android:paddingTop="#dimen/app_bar_top_padding"
app:direction="rtl"
app:font="#string/font_path"
app:navigationIcon="#drawable/m_e_n_u"
app:optionsMenu="#menu/main_menu">
<com.teskaco.bbpos.CustumView.CustomTextView
android:id="#+id/main_title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="#string/psp_name"
android:textColor="#color/colorControlNormal"
android:textSize="#dimen/small_text_size" />
</com.alirezaafkar.toolbar.Toolbar>
<FrameLayout
android:id="#+id/main_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="#+id/buttonPanel" />
<include
android:id="#+id/buttonPanel"
layout="#layout/tab_bottom_menus"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true" />
</RelativeLayout>

Related

Recyclerview is not scrolling

The .xml file is attached below.
The issue is my recycler view is not scrolling.
Also, to show how I'm adding Linearlayout manager, the code is below.
variantRecycler.setLayoutManager(new LinearLayoutManager(getContext(), LinearLayoutManager.VERTICAL, false));
ViewCompat. setNestedScrollingEnabled(variantRecycler, false);
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
app:layout_behavior="#string/appbar_scrolling_view_behavior"
android:layout_width="match_parent"
android:background="#color/transparent"
android:layout_height="match_parent">
<TextView
android:id="#+id/cross_icon"
style="#style/icon"
android:layout_width="#dimen/_30dp"
android:layout_height="#dimen/_30dp"
android:layout_gravity="right"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:layout_marginEnd="#dimen/_10dp"
android:layout_marginRight="#dimen/_20dp"
android:layout_marginBottom="#dimen/_30dp"
android:background="#drawable/circular_cross_button" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_40dp"
android:background="#color/app_grey"
android:orientation="vertical">
<RelativeLayout
android:id="#+id/product_details_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#color/white">
<TextView
android:id="#+id/pick_your_option_label"
style="#style/subheading_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="#dimen/_15dp"
android:layout_marginTop="#dimen/_15dp"
android:layout_marginBottom="#dimen/_10dp"
android:text="#string/pick_your_option"
android:textColor="#color/product_name_lite_black_color"
android:textSize="#dimen/_18dp"
android:visibility="gone" />
<View
android:id="#+id/line1"
android:layout_width="match_parent"
android:layout_height="#dimen/_1dp"
android:layout_below="#id/pick_your_option_label"
android:layout_marginLeft="#dimen/_15dp"
android:layout_marginTop="#dimen/_10dp"
android:layout_marginRight="#dimen/_15dp"
android:layout_marginBottom="#dimen/_15dp"
android:background="#color/line_color"
android:visibility="invisible" />
<androidx.viewpager2.widget.ViewPager2
android:id="#+id/view_pager"
android:layout_width="#dimen/_136dp"
android:layout_height="#dimen/_136dp"
android:layout_below="#id/line1"
android:layout_marginLeft="#dimen/_16dp"
android:layout_marginTop="#dimen/_12dp"
android:layout_marginRight="#dimen/_12dp"
android:layout_marginBottom="#dimen/_8dp"
android:background="#drawable/grey_border_rounder_rectangle_8dp"
android:padding="#dimen/_1dp"
android:transitionName="#string/image" />
<LinearLayout
android:id="#+id/pager_dots"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#+id/view_pager"
android:layout_gravity="center"
android:layout_marginLeft="#dimen/_16dp"
android:layout_marginBottom="#dimen/_15dp"
android:background="#android:color/transparent"
android:orientation="horizontal" />
<ImageView
android:id="#+id/product_image"
android:layout_width="#dimen/_120dp"
android:layout_height="#dimen/_120dp"
android:layout_marginLeft="#dimen/_10dp"
android:layout_marginRight="#dimen/_8dp"
android:layout_marginBottom="#dimen/_15dp"
android:transitionName="#string/image"
android:visibility="gone" />
<ImageView
android:id="#+id/elite_image"
android:layout_width="#dimen/_16dp"
android:layout_height="#dimen/_16dp"
android:layout_below="#id/line1"
android:layout_marginLeft="#dimen/_15dp"
android:visibility="gone"
app:srcCompat="#drawable/elite_icon" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
</RelativeLayout>
<TextView
android:id="#+id/product_name"
style="#style/body_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/line1"
android:layout_marginTop="#dimen/_12dp"
android:layout_marginRight="#dimen/_10dp"
android:layout_toRightOf="#id/view_pager"
android:ellipsize="end"
android:maxLines="2"
android:textColor="#color/product_name_lite_black_color" />
<View
android:id="#+id/view"
android:layout_width="1dp"
android:layout_toRightOf="#id/product_name"
android:layout_marginTop="#dimen/_12dp"
android:layout_marginLeft="#dimen/_3dp"
android:background="#color/divider_grey"
android:layout_height="#dimen/_35dp"/>
<TextView
style="#style/icon"
android:id="#+id/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_12dp"
android:layout_gravity="center"
android:layout_toRightOf="#+id/view"
android:layout_marginLeft="#dimen/_3dp"
android:layout_marginRight="#dimen/_5dp"
android:background="?selectableItemBackground"
android:gravity="center"
android:text="#string/camera_icon_id"
android:textSize="#dimen/_24dp"
android:textStyle="bold" />
<TextView
android:id="#+id/try_on"
style="#style/subheading_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_3dp"
android:layout_toRightOf="#id/view"
android:layout_below="#+id/icon"
android:textColor="#color/add_to_cart_violet" />
<TextView
android:id="#+id/price"
style="#style/subheading_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/product_name"
android:layout_marginTop="#dimen/_8dp"
android:layout_toRightOf="#id/view_pager"
android:textColor="#color/product_name_lite_black_color" />
<TextView
android:id="#+id/offer_price"
style="#style/subheading_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/product_name"
android:layout_marginLeft="#dimen/_4dp"
android:layout_marginTop="#dimen/_8dp"
android:layout_toRightOf="#id/price"
android:textColor="#color/product_mrp_lite_gray_color" />
<TextView
android:id="#+id/save_offer"
style="#style/caption_manrope_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/product_name"
android:layout_marginLeft="#dimen/_4dp"
android:layout_marginTop="#dimen/_10dp"
android:layout_toRightOf="#id/offer_price"
android:textColor="#color/product_offer_price_color"
android:textSize="#dimen/_13dp"
android:visibility="gone" />
<TextView
android:id="#+id/offer_percantage"
style="#style/caption_manrope_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/product_name"
android:layout_marginLeft="#dimen/_2dp"
android:layout_marginTop="#dimen/_10dp"
android:layout_toRightOf="#id/save_offer"
android:textColor="#color/product_offer_price_color"
android:textSize="#dimen/_13dp" />
<include
layout="#layout/new_rating_layout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/price"
android:layout_marginTop="#dimen/_8dp"
android:layout_toRightOf="#id/view_pager" />
<TextView
android:id="#+id/product_qty"
style="#style/caption_manrope_medium2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#+id/new_rating_layout"
android:layout_marginLeft="#dimen/_12dp"
android:layout_marginTop="#dimen/_11dp"
android:layout_toRightOf="#id/view_pager"
android:gravity="center_vertical"
android:text="20ml"
android:textColor="#color/ash_gray"
android:textSize="#dimen/_10dp" />
<HorizontalScrollView
android:layout_below="#+id/product_qty"
android:layout_toRightOf="#id/view_pager"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/_6dp"
android:layout_marginLeft="#dimen/_12dp"
android:scrollbars="none">
<com.google.android.material.chip.ChipGroup
android:id="#+id/chip_group"
app:singleLine="true"
app:singleSelection="true"
android:layout_width="match_parent"
android:layout_height="wrap_content"
/>
</HorizontalScrollView>
<View
android:id="#+id/line2"
android:layout_width="match_parent"
android:layout_height="#dimen/_1dp"
android:layout_below="#id/view_pager"
android:layout_marginLeft="#dimen/_15dp"
android:layout_marginTop="#dimen/_10dp"
android:layout_marginRight="#dimen/_15dp"
android:layout_marginBottom="#dimen/_10dp"
android:background="#color/line_color"
android:visibility="invisible" />
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#+id/product_details_layout"
android:layout_marginTop="#dimen/_8dp"
android:background="#color/white">
<TextView
android:id="#+id/shades_label"
style="#style/body_manrope_bold"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="#dimen/_2dp"
android:layout_marginTop="#dimen/_8dp"
android:layout_marginBottom="#dimen/_5dp"
android:layout_toRightOf="#+id/shade"
android:textColor="#color/dark_gray_color"
android:textStyle="bold"
android:visibility="gone" />
<androidx.recyclerview.widget.RecyclerView
android:id="#+id/variant_recycler"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:nestedScrollingEnabled="false"
android:layout_below="#+id/shade"
/>
</RelativeLayout>
</RelativeLayout>
<include
layout="#layout/variant_pop_up_bottom_bar_layout"
android:visibility="visible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>

ScrollView is not working inside drawer layout. I have put scroll inside navigation view.but it's not working

ScrollView is not working inside drawer layout. I have put scroll inside navigation view.but it's not working .
In following code HomeView.cs is View to show drawer layout. SliderView.cs is layout of the drawer.I have taken listview to show menu inside navigation drawer.but it's not working
I have taken frame layout because I want to show inside fragment.
//HomeView.axml
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:background="#color/colorWhite"
android:id="#+id/rootLayout"
android:layout_height="wrap_content">
<ImageView
android:layout_height="match_parent"
android:src="#drawable/back_radient"
android:id="#+id/bluryImg"
android:visibility="gone"
android:scaleType="centerCrop"
android:layout_width="match_parent"/>
<RelativeLayout
android:visibility="visible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="#+id/NotificationDrawerLayout"
android:background="#37CADD">
<RelativeLayout
android:layout_width="match_parent"
android:background="#37CADD"
android:padding="10dp"
android:id="#+id/notificationDrawerBarLayout"
android:minHeight="50dp"
android:layout_height="wrap_content">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textSize="#dimen/textSize_15"
android:id="#+id/NotificationDrawerText"
android:textColor="#ffffff"
android:textStyle="normal"
android:gravity="center"
android:layout_centerInParent="true"
android:text="Composition Created Successfully" />
</RelativeLayout>
</RelativeLayout>
<android.support.v4.widget.DrawerLayout
android:id="#+id/drawer"
android:visibility="visible"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<include
android:id="#+id/headerLayout"
layout="#layout/HeaderView"
android:layout_alignParentTop="true" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="#+id/contentFrameRootLayout"
android:layout_below="#+id/headerLayout">
<FrameLayout
android:id="#+id/content_frameLayout"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</RelativeLayout>
</RelativeLayout>
<FrameLayout
android:id="#+id/navigation_frame"
android:layout_height="match_parent"
android:layout_width="wrap_content"
android:layout_gravity="left|start" />
</android.support.v4.widget.DrawerLayout>
</RelativeLayout>
//SliderView.axml
<?xml version="1.0" encoding="utf-8"?>
<ScrollView
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="#+id/scroll"
android:layout_width="match_parent"
android:fillViewport="true"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="wrap_content"
android:orientation="vertical"
android:layout_height="match_parent">
<android.support.design.widget.NavigationView
android:id="#+id/navigation_view"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:background="#drawable/side_menu"
android:layout_gravity="start">
<RelativeLayout
android:layout_width="match_parent"
android:id="#+id/topSliderView"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:orientation="vertical"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageButton
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="#+id/btnDrawerClose"
android:layout_marginLeft="#dimen/margin_05"
android:layout_marginTop="#dimen/margin_25"
android:padding="#dimen/padding_10"
android:src="#drawable/humbergerclose"
android:background="#null"
android:tint="#ffffff" />
<refractored.controls.CircleImageView
android:id="#+id/profile"
android:layout_below="#+id/btnDrawerClose"
android:layout_width="80dp"
android:scaleType="centerCrop"
android:layout_height="80dp"
android:transitionName="EXTRA_IMAGE"
android:src="#drawable/user2"
app:civ_border_width="0dp"
android:layout_centerHorizontal="true" />
<TextView
android:id="#+id/txtViewName"
android:layout_width="match_parent"
android:layout_below="#id/profile"
android:layout_height="wrap_content"
android:text="Darshan Prajpati"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:gravity="center_horizontal"
android:layout_marginTop="#dimen/margin_10" />
<TextView
android:id="#+id/txtViewEmail"
android:layout_width="match_parent"
android:layout_below="#id/txtViewName"
android:layout_height="wrap_content"
android:text="dkprajpati18#gmail.com"
android:textSize="#dimen/textSize_14"
android:textColor="#color/colorWhite"
android:gravity="center_horizontal"
android:layout_marginTop="#dimen/margin_10" />
<ListView
android:id="#+id/menuItemListView"
android:scrollbars="none"
android:layout_marginTop="#dimen/margin_10"
android:layout_width="match_parent"
android:layout_below="#id/txtViewEmail"
android:layout_height="wrap_content"
android:divider="#null" />
</RelativeLayout>
<Space
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<RelativeLayout
android:id="#+id/setting2ItemLayout"
android:layout_height="49dp"
android:layout_width="match_parent"
android:layout_marginLeft="#dimen/margin_20"
android:padding="#dimen/padding_05">
<ImageView
android:id="#+id/SettingImgView"
android:layout_height="wrap_content"
android:src="#drawable/Settings"
android:layout_width="18dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="#+id/SettingsTxtView"
android:text="Settings"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:layout_toRightOf="#+id/SettingImgView"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerVertical="true" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/setting1ItemLayout"
android:layout_height="49dp"
android:layout_below="#+id/setting2ItemLayout"
android:layout_width="match_parent"
android:layout_marginLeft="#dimen/margin_20"
android:padding="#dimen/padding_05">
<ImageView
android:id="#+id/SettingImgView"
android:layout_height="wrap_content"
android:src="#drawable/Settings"
android:layout_width="18dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="#+id/SettingsTxtView"
android:text="Settings"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:layout_toRightOf="#+id/SettingImgView"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerVertical="true" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/settingItemLayout"
android:layout_below="#+id/setting1ItemLayout"
android:layout_height="49dp"
android:layout_width="match_parent"
android:layout_marginLeft="#dimen/margin_20"
android:padding="#dimen/padding_05">
<ImageView
android:id="#+id/SettingImgView"
android:layout_height="wrap_content"
android:src="#drawable/Settings"
android:layout_width="18dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="#+id/SettingsTxtView"
android:text="Settings"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:layout_toRightOf="#+id/SettingImgView"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerVertical="true" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/FAQItemLayout"
android:layout_below="#+id/settingItemLayout"
android:layout_height="49dp"
android:layout_width="match_parent"
android:layout_marginLeft="#dimen/margin_20"
android:padding="#dimen/padding_05">
<ImageView
android:id="#+id/FAQImgView"
android:layout_height="wrap_content"
android:src="#drawable/faq"
android:layout_width="18dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="#+id/FAQTxtView"
android:text="FAQs"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:layout_toRightOf="#+id/FAQImgView"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerVertical="true" />
</RelativeLayout>
<RelativeLayout
android:id="#+id/LogoutItemLayout"
android:layout_below="#+id/FAQItemLayout"
android:layout_height="49dp"
android:layout_width="match_parent"
android:layout_marginLeft="#dimen/margin_20"
android:padding="#dimen/padding_05">
<ImageView
android:id="#+id/LogoutImgView"
android:layout_height="wrap_content"
android:src="#drawable/Logout"
android:layout_width="18dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="#+id/LogoutTxtView"
android:text="Logout"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_16"
android:textColor="#color/colorWhite"
android:layout_toRightOf="#+id/LogoutImgView"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerVertical="true" />
</RelativeLayout>
<ImageView
android:id="#+id/betaLogo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="#drawable/ratiomenulogo"
android:layout_centerHorizontal="true"
android:layout_below="#+id/LogoutItemLayout"
android:layout_marginBottom="10dp"
android:layout_marginTop="10dp"
/>
<TextView
android:id="#+id/versionTxtView"
android:text="Version 1.1.20"
android:layout_height="wrap_content"
app:fontFamily="#font/lato_regular"
android:layout_width="wrap_content"
android:textSize="#dimen/textSize_12"
android:textColor="#1DD5A5"
android:layout_toRightOf="#+id/LogoutImgView"
android:layout_marginBottom="20dp"
android:layout_below="#id/betaLogo"
android:layout_marginLeft="#dimen/margin_20"
android:layout_centerHorizontal="true" />
</RelativeLayout>
</LinearLayout>
</RelativeLayout>
</android.support.design.widget.NavigationView>
</LinearLayout>
</ScrollView>
//HomeView.cs
public class HomeView : MvxAppCompatActivity<BaseViewModel>
{
protected override void OnCreate(Bundle savedInstanceState)
{
base.OnCreate(savedInstanceState);
SetContentView(Resource.Layout.HomeView);
if (savedInstanceState == null)
{
MenuFragment menuFragment = new MenuFragment();
var fragmenttransaction = this.SupportFragmentManager.BeginTransaction();
fragmenttransaction.Replace(Resource.Id.navigation_frame, menuFragment, "MenuFragment");
fragmenttransaction.AddToBackStack("MenuFragment");
fragmenttransaction.Commit();
NavigateToFragment<ProposalListFragment>("ProposalListFragment", true);
}
}
}

CardView size issue on View Recycle

I have created a recyclerview adapter class, with an item layout which contains a cardview inside which there are some textviews and imageviews. The problem I am facing is that when the views are recycled, my cardview size changes and it hides the content of another cardview.
I think the issue is because I have different card heights for each item. So when an item is recycled, it takes the height of another card which is different. How to fix this? Please help..
Video link of the problem: https://drive.google.com/file/d/1nlgq-eQ-rhRNadOyzg4FwjVzrIk88Ve8/view?usp=sharing
open_up_list_view.xml
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<RelativeLayout 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="wrap_content">
<android.support.v7.widget.CardView
android:id="#+id/openUpCardView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="#dimen/nav_header_vertical_spacing"
android:layout_marginEnd="#dimen/dimen_16x"
android:layout_marginLeft="#dimen/activity_vertical_margin"
android:layout_marginRight="#dimen/dimen_16x"
android:layout_marginStart="#dimen/activity_vertical_margin"
android:layout_marginTop="#dimen/dimen_4x"
android:clickable="true"
android:focusable="true"
app:cardCornerRadius="#dimen/dimen_8x">
<RelativeLayout
android:id="#+id/openUpRelativeLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="#dimen/dimen_8x"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal">
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ProgressBar
android:id="#+id/openUpAuthorImageProgress"
android:layout_width="wrap_content"
android:layout_height="match_parent" />
<de.hdodenhof.circleimageview.CircleImageView
android:id="#+id/openUpAuthorImage"
android:layout_width="#dimen/dimen_48x"
android:layout_height="#dimen/dimen_48x"
android:layout_marginBottom="#dimen/dimen_4x"
android:layout_marginLeft="#dimen/dimen_4x"
android:layout_marginRight="#dimen/dimen_4x"
android:layout_marginTop="#dimen/dimen_4x"
app:civ_border_color="#FF000000"
app:civ_border_width="2dp" />
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="#+id/openUpAuthorName"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="#dimen/cardview_default_radius"
android:layout_marginLeft="#dimen/dimen_8x"
android:layout_marginRight="#dimen/dimen_8x"
android:layout_marginTop="#dimen/dimen_8x"
android:text="loading.."
android:textColor="#color/colorPrimaryDark"
android:textSize="#dimen/dimen_16x"
android:textStyle="bold" />
<TextView
android:id="#+id/openUpDate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/openUpAuthorName"
android:layout_marginLeft="#dimen/dimen_8x"
android:textSize="#dimen/dimen_12x" />
</RelativeLayout>
</LinearLayout>
<TextView
android:id="#+id/openUpTextView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_gravity="left"
android:autoLink="web"
android:padding="#dimen/dimen_4x"
android:textAlignment="textStart"
android:textColor="#color/cardview_dark_background"
android:textSize="#dimen/dimen_16x" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ProgressBar
android:id="#+id/openUpImageProgress"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<com.github.chrisbanes.photoview.PhotoView
android:id="#+id/openUpImageView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="#dimen/dimen_8x"
android:layout_marginLeft="#dimen/dimen_4x"
android:layout_marginRight="#dimen/dimen_4x"
android:layout_marginTop="#dimen/dimen_8x"
android:layout_weight="1"
app:srcCompat="#drawable/common_google_signin_btn_icon_dark" />
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="0.5dp"
android:background="#android:color/darker_gray"
android:hapticFeedbackEnabled="false"></View>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal">
<CheckBox
android:id="#+id/openUpLikeIcon"
android:layout_width="#dimen/dimen_32x"
android:layout_height="#dimen/dimen_24x"
android:layout_marginBottom="#dimen/dimen_4x"
android:layout_marginLeft="16dp"
android:layout_marginStart="16dp"
android:layout_marginTop="8dp"
android:background="#drawable/thumb_off"
android:button="#null"
android:checked="false"
android:clickable="true"
android:focusable="true"
android:stateListAnimator="#animator/scale"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toBottomOf="#+id/image" />
<TextView
android:id="#+id/openUpLikeTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="#dimen/nav_header_vertical_spacing"
android:layout_marginTop="#dimen/dimen_8x"
android:text="loading.."
android:textSize="#dimen/dimen_16x" />
<ImageView
android:id="#+id/openUpCommentIcon"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_marginLeft="#dimen/fab_margin"
android:layout_marginTop="#dimen/dimen_8x"
app:srcCompat="#drawable/comment_icon" />
<TextView
android:id="#+id/openUpCommentTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/dimen_8x"
android:text="loading.."
android:textSize="#dimen/dimen_16x" />
<TextView
android:id="#+id/openUpDeleteText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="#dimen/dimen_4x"
android:layout_marginTop="#dimen/dimen_8x"
android:layout_weight="1"
android:gravity="center_horizontal"
android:text="Delete"
android:textSize="#dimen/dimen_16x" />
</LinearLayout>
<View
android:id="#+id/commentSeparatorView"
android:layout_width="match_parent"
android:layout_height="1.5dp"
android:layout_marginTop="#dimen/nav_header_vertical_spacing"
android:background="#color/colorPrimaryDark"
android:hapticFeedbackEnabled="false"></View>
<TextView
android:id="#+id/commentSeparatorText"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="#dimen/dimen_8x"
android:gravity="center"
android:text="Comments"
android:textColor="#color/common_google_signin_btn_text_dark_focused" />
<LinearLayout
android:id="#+id/commentsLL"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="#dimen/dimen_4x"
android:background="#null"
android:orientation="vertical">
<android.support.v7.widget.RecyclerView
android:id="#+id/commentsRecyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</android.support.v7.widget.RecyclerView>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal">
<android.support.design.widget.TextInputLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:hint="Add a comment..">
<android.support.design.widget.TextInputEditText
android:id="#+id/commentEditText"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</android.support.design.widget.TextInputLayout>
<android.support.v7.widget.AppCompatButton
android:id="#+id/commentPostButton"
android:layout_width="80dp"
android:layout_height="wrap_content"
android:backgroundTint="#color/colorPrimaryDark"
android:text="POST"
android:textColor="#color/cardview_light_background" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</android.support.v7.widget.CardView>
</RelativeLayout>
</ScrollView>
EDIT: RecyclerView layout
fragment_open_up.xml
<FrameLayout 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"
tools:context="com.bittentech.localvariable.fragments.OpenUpFragment">
<!-- TODO: Update blank fragment layout -->
<TextView
android:id="#+id/openUpEmptyView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical|center_horizontal"
android:gravity="center_vertical|center_horizontal"
android:text="All caught up!!" />
<android.support.v4.widget.SwipeRefreshLayout
android:id="#+id/openUpSwipeRefresh"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView
android:id="#+id/openUpRecyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:nestedScrollingEnabled="false"/>
</android.support.v4.widget.SwipeRefreshLayout>
</FrameLayout>

Android layout with fixed button on bottom

I have the following xml which is supposed to be something similar to the following
The activity shows mostly ok, but i cant get the two down buttons to get fixed to the bottom of the screen without messing the top views.
I've tried to use a FrameLayout with two RelativeLayouts, alignment_bottom, an empty view with weight 1 between components and even still havent being able to accomplish my goal. Any help will be really appreciated, thank you in advance.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:layout_width="match_parent"
android:orientation="vertical"
android:layout_height="match_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<ScrollView android:layout_width="match_parent" android:layout_height="match_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="#+id/RelativeLayout1">
<ImageView
android:id="#+id/group_info_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:scaleType="fitStart"
android:adjustViewBounds="true"
android:layout_alignParentTop="true"
/>
<TextView
android:id="#+id/description_text"
android:layout_below="#id/group_info_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="#color/mainColor"
android:textSize="20sp"
android:text="#string/descripcion"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:fontFamily="sans-serif"
/>
<TextView
android:layout_below="#id/description_text"
android:gravity="start"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="#+id/group_info_description"
android:layout_marginTop="5dp"
android:layout_marginBottom="10dp"
android:layout_marginStart="10dp"
android:textSize="15sp"/>
<TextView
android:layout_below="#id/group_info_description"
android:scrollbars="vertical"
android:gravity="center"
android:textColor="#android:color/black"
android:layout_marginTop="10dp"
android:layout_marginStart="5dp"
android:layout_marginBottom="2dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="#+id/group_info_user_number"
android:textSize="15sp"
/>
<es.tretornesp.clickerchat.NonScrollableListView
android:layout_below="#id/group_info_user_number"
android:id="#+id/group_info_user_list"
android:layout_height="match_parent"
android:divider="#drawable/list_divider"
android:dividerHeight="1px"
android:layout_width="match_parent"/>
</RelativeLayout>
</ScrollView>
<LinearLayout
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Button
android:id="#+id/delete_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="#string/borrar_grupo"
android:background="#color/mainColor" />
<View
android:id="#+id/divisor"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#color/grey"/>
<Button
android:id="#+id/exit_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="#android:color/white"
android:text="#string/salir"
android:background="#color/mainColor"
/>
</LinearLayout>
</LinearLayout>
Change your layout file as below,
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="#+id/exit_group">
<RelativeLayout
android:id="#+id/RelativeLayout1"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:id="#+id/group_info_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:adjustViewBounds="true"
android:scaleType="fitStart" />
<TextView
android:id="#+id/description_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#id/group_info_image"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:fontFamily="sans-serif"
android:text="#string/descripcion"
android:textColor="#color/mainColor"
android:textSize="20sp" />
<TextView
android:id="#+id/group_info_description"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#id/description_text"
android:layout_marginBottom="10dp"
android:layout_marginStart="10dp"
android:layout_marginTop="5dp"
android:gravity="start"
android:textSize="15sp" />
<TextView
android:id="#+id/group_info_user_number"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#id/group_info_description"
android:layout_marginBottom="2dp"
android:layout_marginStart="5dp"
android:layout_marginTop="10dp"
android:gravity="center"
android:scrollbars="vertical"
android:textColor="#android:color/black"
android:textSize="15sp" />
<es.tretornesp.clickerchat.NonScrollableListView
android:id="#+id/group_info_user_list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="#id/group_info_user_number"
android:divider="#drawable/list_divider"
android:dividerHeight="1px" />
<Button
android:id="#+id/delete_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="#+id/group_info_user_list"
android:background="#color/mainColor"
android:text="#string/borrar_grupo" />
<View
android:id="#+id/divisor"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="#id/delete_group"
android:background="#color/grey" />
</RelativeLayout>
</ScrollView>
<Button
android:id="#+id/exit_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="#color/mainColor"
android:text="#string/salir"
android:textColor="#android:color/white" />
</RelativeLayout>
Use Coordinator Layout as a parent layout. like this.
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:card_view="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="false">
// your code
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:orientation="horizontal">
<TextView
android:id="#+id/txt_contact_laksha_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="demo"
/>
</LinearLayout>
</android.support.design.widget.CoordinatorLayout>

How to put a TextView at the end of my ScrollView?

I want to add a TextView at the bottom of my ScrollView, in which I can put the version number. So when a user first enters the screen, they don't see the Version Number. After they Scroll down, they can see the version number at the bottom of the screen. I tried all kinds of ways, doesn't work.
The layout is pretty nested.
This is the screenshot of the layout implementing the code below
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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">
<ScrollView
android:id="#+id/scrollView"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="#+id/linearLayoutThatDoesNotScroll"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#drawable/bg_splash"
android:clickable="true"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="#dimen/cnt_full">
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="false"
android:layout_centerVertical="true"
android:layout_gravity="center">
<com.onkore.app.view.FontTextView
android:id="#+id/profile_num_trophies_won"
style="#style/Theme.App.Text.Headline"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginTop="#dimen/cnt_half"
android:drawablePadding="#dimen/cnt_tiny"
android:drawableStart="#drawable/icon_trophy"
android:fontFamily="thick"
android:gravity="center_vertical"
android:text="99"
android:textColor="#color/color_text_primary_inverse"
android:textSize="32sp" />
<com.onkore.app.view.FontTextView
style="#style/Theme.App.Text.Caption"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/profile_num_trophies_won"
android:text="#string/profile_trophies"
android:textColor="#color/color_text_primary_inverse" />
</RelativeLayout>
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true">
<com.makeramen.roundedimageview.RoundedImageView
android:id="#+id/profile_user_pic"
android:layout_width="#dimen/profile_image_size"
android:layout_height="#dimen/profile_image_size"
android:layout_centerInParent="true"
android:layout_centerVertical="false"
android:src="#drawable/icon_profile_default"
app:riv_oval="true" />
<com.mikhaellopez.circularprogressbar.CircularProgressBar
android:id="#+id/profile_progress_bar"
android:layout_width="#dimen/profile_progress_bar_size"
android:layout_height="#dimen/profile_progress_bar_size"
android:layout_centerHorizontal="false"
android:layout_centerInParent="true"
android:layout_centerVertical="false"
app:cpb_background_progressbar_color="#color/color_base"
app:cpb_background_progressbar_width="#dimen/elev_06"
app:cpb_progress="25"
app:cpb_progressbar_color="#color/color_progress"
app:cpb_progressbar_width="#dimen/cnt_tiny" />
<com.onkore.app.view.FontTextView
android:id="#+id/profile_level"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="#id/profile_progress_bar"
android:layout_centerHorizontal="true"
android:layout_centerInParent="false"
android:layout_marginTop="#dimen/cnt_dbl"
android:textColor="#color/color_text_primary_inverse"
android:textSize="#dimen/text_size"
tools:text="Level 99" />
</RelativeLayout>
<com.onkore.app.view.FontTextView
android:id="#+id/profile_okoins"
style="#style/Theme.App.Coins.Balance"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
android:layout_centerVertical="true"
android:layout_gravity="center_vertical"
tools:text="999k" />
</RelativeLayout>
<com.onkore.app.view.FontTextView
style="#style/Theme.App.Tile.Text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="#dimen/cnt_full"
android:layout_marginStart="#dimen/cnt_full"
android:layout_marginTop="#dimen/cnt_full"
android:background="#drawable/bg_card_empty"
android:gravity="center"
android:paddingBottom="#dimen/cnt_dbl"
android:paddingTop="#dimen/cnt_part"
android:text="Tap to Personalize"
android:textAllCaps="true"
android:visibility="gone" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#color/color_primary_translucent"
android:visibility="gone">
<com.onkore.app.view.FontTextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Friends" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="50dp"
>
<TextView
android:id="#+id/versionName"
android:layout_width="match_parent"
android:layout_height="40dp"
android:background="#color/cardview_dark_background"
android:gravity="center_vertical|center_horizontal|center"
android:text="HAHA"
android:textColor="#color/cardview_light_background"
android:visibility="visible" />
</LinearLayout>
</LinearLayout>
</ScrollView>
</RelativeLayout>
maybe something like this?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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"
tools:layout_editor_absoluteX="8dp"
tools:layout_editor_absoluteY="8dp">
<ScrollView
android:id="#+id/scrollView"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="#+id/linearLayoutThatDoesNotScroll"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#color/colorAccent"
android:clickable="true"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="1000dp" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:text="version"
android:textSize="50dp" />
</LinearLayout>
</ScrollView>
</RelativeLayout>

Categories

Resources