I wanted to know how I can configure a background image, so that it can be seen on the entire screen, remove the ActionBar and I want to make the notification bar transparent so that the image can be seen there too. Thanks in advance.
Had treated:
<ImageView
android:id="@+id/imageView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/background"/>
Several options, the first would be defining an image as background through the property
android:background
The second, through a
ImageView
with properties,android:layout_width="match_parent"
andandroid:layout_height="match_parent"
, defining an image with the propertyandroid:background
:the third through an ImageView, using the property
android:scaleType="fitXY"
:and the fourth, defining a theme, where you define the image :
and load it from your activity, defining the theme in the
AndroidManifest.xml
For the background image, give the Layout a background with
android:background="@drawable/background_game_screen"
, example:For the transparency of the notification bar, try placing this in your theme:
And if you want to remove the ActionBar do it with this:
or via code: