The string(s) in
res/values-land/strings.xml
res/values/strings.xml
res/values-land/strings.xml
.res/values-port
,res/values
LandActivity.java
:
untouched.res/layout/main.xml
:
untouched.res/values/strings.xml
res/values-land/strings.xml
AndroidManifest.xml
:
untouched.
Create a new folder named
values-land
res
folder.
In the Package Explorer, right-click on
res
and select
New → Folder
Name the new folder
values-land
.
Create a new file named
strings.xml
values-land
folder.
In the Package Explorer, right-click on
values-land
New → File
Name the new file
strings.xml
.
res/values/colors.xml
res/values-land/colors.xml
color
element inside of a
resources
element.
See
color
resources.
res/drawable-hdpi
.res/drawable-land-hdpi
res/drawable-hdpi-land
;myimage.jpg
and then drag the file into
drawable-hdpi
.myimage.jpg
in
res/drawable-land-hdpi
.LinearLayout
in
main.xml
TextView
.
<ImageView android:layout_height="wrap_content" android:layout_width="wrap_content" android:src="@drawable/myimage" />You can add the
android:gravity="center"
LinearLayout
,
and the attribute
android:gravity="center"
TextView
.