바둑판 식 이미지를 프로그램 배경으로 추가하려고합니다.XMLView에 ImageView를 추가하면 프로그램이 예기치 않게 멈 춥니 다.
충돌되어 나는 현재 main.xml에에서 사용하고 코드 :
<?xml version="1.0" encoding="utf-8"?>
<ImageView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/cartoonclouds"
android:contentDescription="@string/desc" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/hello" />
</LinearLayout>
</ImageView>
을하지만, ImageView
이 제거되고 xmlns
가 LinearLayout
로 이동 될 때, 그것은의없이 (고급 기능 코스, 이미지).
LogCat에서 관련 오류를 볼 수 없습니다.
더 많은 정보 :
이클립스와 안드로이드 2.2, API (8) 프로그램이 실행하지만, 사용 즉시 충돌합니다.
완벽하게 일을했다. 그러나 이미지를 어떻게 타일링 할 수 있습니까? –
나는 그것을 모른다. 나는 한번도 시도한 적이 없다. 'ImageView'를 사용하면 이미지의 크기를 조절할뿐입니다. 'background' 속성은 같은 것을합니다. 가능하다면 나는 궁금해서 다른 질문을 할 수도 있습니다. – DeeV
http://stackoverflow.com/questions/8899222/tiling-images-in-android-with-imageview-in-xml –