To be accurate, this refers to the background of the window, rather than the background of Layout. The two are essentially different.
In many articles, the background color of the window actually refers to the background color of the root layout. The so-called window should be the host of the root layout. Make the root layout a little smaller and the screen is not full. The exposed root layout is still black.
To put it bluntly, go to the Code:
[Java]
Window window = getWindow ();
ColorDrawable colorDrawable = new ColorDrawable (0xFF4612FF );
Window. setBackgroundDrawable (colorDrawable );
Window window = getWindow ();
ColorDrawable colorDrawable = new ColorDrawable (0xFF4612FF );
Window. setBackgroundDrawable (colorDrawable );
Window also has a method to set the background setBackgroundDrawableResource (resid ).
From thick and thin hair, water comes to the fore