How to remove specific space between parent and child in an ExpandableListView

后端 未结 10 2213
太阳男子
太阳男子 2021-02-20 09:10

Can you help me identify why there is a space between the group and the child? In my case I want spaces between all groups and the child should be right below the group with no

10条回答
  •  南旧
    南旧 (楼主)
    2021-02-20 10:01

    this is tested and is proven to work, i wanted to come back to this even months later because none of the other methods gave me results quite how i wanted them. these are displayed exactly how OP (and myself) wanted

    this is my groups or categories or whatever. basically the first linear layout is just a wrapper for a view which acts as a spacer between the categories, and then another linear layout that handles all my formatting

    in the ExpandableListView(not shown) i have the divider height set to 0. the spacing is instead handled by the views

    
    
    
        
    
    
    
    
        
    
    
    
    

    then in the child i have this.

    
    
    
        
    
    
    

提交回复
热议问题