📜  状态栏文本颜色 android - Java 代码示例

📅  最后修改于: 2022-03-11 14:52:24.556000             🧑  作者: Mango

代码示例3
getWindow().setStatusBarColor(ContextCompat.getColor(BookReaderActivity.this, R.color.black));
View decorView = getWindow().getDecorView(); //set status background black 
decorView.setSystemUiVisibility(decorView.getSystemUiVisibility() & ~View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR); //set status text  light