0

세로 화면 스크롤, 가로 페이지 스크롤, 탭 상자 텍스트보기 가로 스크롤 작업 (텍스트보기가 상자).가로 스크롤, 세로 스크롤 및 탭 상자 텍스트 뷰 가로 스크롤 기능을 수행하는 방법

필요한 이미지를 첨부했습니다. 나에게이 스크린을 디자인 할 수있게 약간의 아이디어를 줘. ? 당신은 수평있는 ScrollView를 사용하여, 내가 그런 것을 수직 스크롤 텍스트에 대한 필요한 설계에서 언급하는 모든 일을 할 수있는 말을하려고하는,

(click to see required design)

답변

0
<?xml version="1.0" encoding="utf-8"?> 

<HorizontalScrollView xmlns:android="http://schemas.android.com/apk/res/android" 
    xmlns:tools="http://schemas.android.com/tools" 
    android:id="@+id/horizontalScrollView" 
    android:layout_width="match_parent" 
    android:layout_height="match_parent"> 

    <ScrollView 
     android:id="@+id/scrollView" 
     android:layout_width="wrap_content" 
     android:layout_height="wrap_content"> 

     <GridLayout 
      android:layout_width="match_parent" 
      android:layout_height="match_parent"> 

      <TextView 
       android:id="@+id/textView" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" 
       android:layout_column="1" 
       android:layout_row="0" 
       android:padding="5dp" 
       android:text="Sr. no" 
       android:textAppearance="?android:attr/textAppearanceMedium" /> 

      <TextView 
       android:id="@+id/textView2" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" 
       android:layout_column="2" 
       android:layout_row="0" 
       android:padding="5dp" 
       android:text="Name owner address" 
       android:textAppearance="?android:attr/textAppearanceMedium" /> 

      <TextView 
       android:id="@+id/textView3" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" 
       android:layout_column="3" 
       android:layout_row="0" 
       android:padding="5dp" 
       android:text="Sizes" 
       android:textAppearance="?android:attr/textAppearanceMedium" /> 

      <TextView 
       android:id="@+id/textView4" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" 
       android:layout_column="4" 
       android:layout_row="0" 
       android:padding="5dp" 
       android:text="BHkk" 
       android:textAppearance="?android:attr/textAppearanceMedium" /> 

      <TextView 
       android:id="@+id/textView5" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" 
       android:layout_column="5" 
       android:layout_row="0" 
       android:padding="5dp" 
       android:text="Call et.c." 
       android:textAppearance="?android:attr/textAppearanceMedium" /> 

      <TextView 
       android:id="@+id/textView6" 
       android:layout_width="20dp" 
       android:layout_height="wrap_content" 
       android:layout_column="1" 
       android:layout_row="2" 
       android:text="1" /> 

      <TextView 
       android:id="@+id/textView7" 
       android:layout_width="140dp" 
       android:layout_height="wrap_content" 
       android:layout_column="2" 
       android:layout_row="2" 
       android:text="@string/dummyText" /> 

      <TextView 
       android:id="@+id/textView8" 
       android:layout_width="39dp" 
       android:layout_height="wrap_content" 
       android:layout_column="3" 
       android:layout_row="2" 
       android:text="New Text" /> 

      <TextView 
       android:id="@+id/textView9" 
       android:layout_width="20dp" 
       android:layout_height="wrap_content" 
       android:layout_column="4" 
       android:layout_row="2" 
       android:text="10dp" /> 

      <TextView 
       android:id="@+id/textView10" 
       android:layout_width="50dp" 
       android:layout_height="wrap_content" 
       android:layout_column="5" 
       android:layout_row="2" 
       android:text="New Text" /> 

     </GridLayout> 

    </ScrollView> 


</HorizontalScrollView> 
+0

형제 :

참조 설계를 필요 스크롤 ... 어떻게이 텍스트 스크롤을 실현합니까 –

+0

지금 코드를 체크 아웃, 만약 당신이 여전히 만족, 그렇지 않으면 내 대답, 대답 덕분에 회신을 주셔서 감사합니다 –

+0

답장을 보내 주셔서 감사합니다,하지만 스택은 말합니다 15 명 미만의 평판 때문에 투표 할 수 없습니다. –