[英]Overlap images in view in android
我需要創建一個包含兩個圖像的布局。(我將圖像文件附加到一起)。圖像應該使得第一個圖像與第二個圖像重疊。某些物體可以幫助我,因為我是android的新手實際上有兩個圖像,一個是普通圖像,另一個是帶有斜線,我想使生成的圖像看起來像以下內容
您需要這樣的框架布局:
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/image1"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/image1"/>
<ImageView
android:id="@+id/image2"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/image2"/>
這將使項目彼此重疊。 :)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.