Android开发蒙版引导操作功能
复杂的功能,往往需要在上面加一层蒙版引导用户操作
一、思路:
堆积布局方式
二、效果图:
三、关键代码:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="我是界面内容"
android:textSize="20sp"/>
<!--新手教程-->
<LinearLayout
android:id="@+id/ll_letter_know"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:background="@color/black_tp_new_f"
android:gravity="center"
android:orientation="vertical"
>
<ImageView
android:layout_width="200dp"
android:layout_height="80dp"
android:layout_marginTop="72dp"
android:scaleType="centerCrop"
android:src="@mipmap/letter_new_course_horizontal" />
<ImageView
android:layout_width="75dp"
android:layout_height="150dp"
android:layout_marginRight="25dp"
android:layout_marginTop="72dp"
android:scaleType="centerCrop"
android:src="@mipmap/letter_new_course_vertical" />
<TextView
android:id="@+id/tv_letter_know"
android:layout_width="150dp"
android:layout_height="wrap_content"
android:layout_marginTop="60dp"
android:background="@drawable/guide_tourist_btn_bg"
android:gravity="center"
android:padding="12dp"
android:text="我知道了"
android:textColor="@color/white" />
</LinearLayout>
</FrameLayout>
四、项目demo源码结构图:
有问题或者需要完整源码demo的可以看简介联系我,也可以私信我,我每天都看私信的