Selected tab's color in Bottom Navigation View

前端 未结 10 1968
故里飘歌
故里飘歌 2020-11-28 03:47

I\'m adding a BottomNavigationView to a project, and I would like to have a different text (and icon tint) color for the selected tab (to achieve greying out no

10条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-11-28 04:00

    While making a selector, always keep the default state at the end, otherwise only default state would be used. You need to reorder the items in your selector as:

    
    
        
        
    
    

    And the state to be used with BottomNavigationBar is state_checked not state_selected.

提交回复
热议问题