How to set the text style of a button in selectors?

后端 未结 1 1283
暗喜
暗喜 2020-12-05 05:00

Button selectors allows to define a background for each state of the button, but how can the button\'s text style be defined for each state? My objective is to grey out a bu

1条回答
  •  青春惊慌失措
    2020-12-05 05:24

    Well!

    You can define the Text color for all 4 state, similarly as you defined background for the Button. For example:

    file name: /res/color/text_color.xml

    
    
        
        
        
         
    
    

    Take this file into your Button Style like this:

    
    

    0 讨论(0)
提交回复
热议问题