Android在页面设置背景图片 在页面上设置背景,不需要在布局中设置。 在onCreate方法中加入代码: this.getWindow().setBackgroundDrawableResource(R.drawable.a); R.drawable.a为res资源文件夹下的资源图片a