Change spinner background color but keep arrow

前端 未结 11 1347
予麋鹿
予麋鹿 2020-12-13 01:41

I\'ve read several thing about it but I can\'t find what I need. I want to keep the grey arrow but I want to remove the horizontal bar from the default style and have a whit

11条回答
  •  温柔的废话
    2020-12-13 02:05

    Always while working with spinners, buttons and EditTexts and also needing to insert a drawable, I often wrap the element (spinner, EditText etc.) in a FrameLayout. Check an example:

    
    
                                    
    
                                    
                                
    

    Another important tip is that FrameLayout allows you to set OnClick functions on the drawable, for instance.

提交回复
热议问题