9点会伸展,您必须指定图像中应伸展的区域。您为什么不尝试重复可绘制的能力。像这样:
<xml version="1.0" encoding="utf-8"?>
<LinearLayout
android:id="@+id/YourLayout"
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="@drawable/backrepeat"
>
然后在一个名为backrepeat.xml的XML中
<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
android:src="@drawable/back"
android:tileMode="repeat" />