关键属性:

android:layoutDirection=""

当安卓的layoutDirection = “rtl” 时,箭头在右边显示

布局:

<LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@color/backgroundColor"
        android:orientation="vertical">

        <ExpandableListView
            android:id="@+id/expand_list_view"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layoutDirection="rtl">

        </ExpandableListView>
    </LinearLayout>

布局显示:

关于ExpandableListView上下箭头左右显示的笔记

 

当机器人:的layoutDirection = “ltr” 时,箭头在左边边显示(默认)

 

布局文件:

 <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@color/backgroundColor"
        android:orientation="vertical">

        <ExpandableListView
            android:id="@+id/expand_list_view"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layoutDirection="ltr">

        </ExpandableListView>
    </LinearLayout>

 

布局图片显示:

关于ExpandableListView上下箭头左右显示的笔记

 

OK了〜

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-26
  • 2021-06-11
  • 2021-05-21
  • 2021-09-13
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-07-28
  • 2021-09-15
  • 2022-12-23
  • 2022-12-23
  • 2022-01-25
  • 2022-12-23
相关资源
相似解决方案