How to change color of text in whole application by changing theme

I beginner in UI designing, I'm trying to build an app that can change theme as an additional option. As the theme switches to black ToolBar and TabLayout Turns black and I'm using default font color "Black" as is suitable for white theme. Please help me, how to set text color such that it will change in theme.


You can try the Following

public void onCreate(Bundle savedInstanceState) {
    setTheme(android.R.style.Theme);
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_second);
}

Where Theme is your Style that is to Be Implemented

How to change app default theme to a different app theme?

Check these Doc Please

链接地址: http://www.djcxy.com/p/87332.html

上一篇: C#的readonly与C ++的const

下一篇: 如何通过改变主题来改变整个应用程序中的文本颜色