How to preview Android ListView with custom row and header layout

后端 未结 2 1266
粉色の甜心
粉色の甜心 2020-12-29 02:23

I have created a list view with a custom layout for the header and rows items many times but what always annoys me is the UI preview in Android Studio does not show a previe

2条回答
  •  梦谈多话
    2020-12-29 02:57

    You can use tools:listitem. Just add the tools namespace in the root of the layout

    and then in your ListView set your list item layout

     

    enter image description here

    Is also possible to set header/footer with listheader/listfooter.

提交回复
热议问题