I am trying to implement horizontal and vertical scrolling for a Recycler view at the same time.I have to show a table of 8 columns, so I plan to implement horizontal and vertical scrolling at the same time.
I tried HorizontalScrollView but it is scrolling horizontally in one row.
list_row.xml
<?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"
android:focusable="true"
android:clickable="true"
android:background="?android:attr/selectableItemBackground"
android:orientation="vertical">
<HorizontalScrollView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal" >
<TextView
android:id="@+id/title"
android:textColor="@color/title"
android:textSize="16dp"
android:textStyle="bold"
android:layout_alignParentTop="true"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="aaa"/>
<TextView
android:id="@+id/genre"
android:layout_below="@id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:text="bbb"/>
<TextView
android:id="@+id/year"
android:textColor="@color/year"
android:layout_width="wrap_content"
android:layout_alignParentRight="true"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:text="ccc"/>
</LinearLayout>
</HorizontalScrollView>
</RelativeLayout>
is there any way to scroll the list horizontally and vertically by the entire table in the same layout.