title: How to make transparent cut in another transparent background?
body: <p>I would like to make tutorial of new elements in layout, where I put another layer on my whole view. Then I would like to cut some places to see the layer underneath. In brief cut out that adjusts to the element underneath.</p>
  <p>Now I make another black transparent layout.
  Then create another layout with white transparent, but it doesn't clean, delete my area with black transparent so effect is like in picture. This place should be with transparent white to see what is underneath. In code look at <code>@+id/test</code></p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;
  &lt;androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
      xmlns:app=&quot;http://schemas.android.com/apk/res-auto&quot;
      xmlns:tools=&quot;http://schemas.android.com/tools&quot;
      android:layout_width=&quot;match_parent&quot;
      android:layout_height=&quot;match_parent&quot;
      android:focusableInTouchMode=&quot;true&quot;&gt;
  
    
  
      &lt;LinearLayout
          android:layout_width=&quot;match_parent&quot;
          android:layout_height=&quot;match_parent&quot;
          android:orientation=&quot;vertical&quot;
          app:layout_behavior=&quot;@string/appbar_scrolling_view_behavior&quot;&gt;
  [ my linear layout with elements]
      
                  &lt;/LinearLayout&gt;
  
      &lt;androidx.constraintlayout.widget.ConstraintLayout
          android:id=&quot;@+id/tutorial&quot;
          android:layout_width=&quot;match_parent&quot;
          android:layout_height=&quot;match_parent&quot;
          android:background=&quot;@color/tutorial_background&quot;&gt;
  
          &lt;androidx.constraintlayout.widget.ConstraintLayout
              android:id=&quot;@+id/test&quot;
              android:layout_width=&quot;380dp&quot;
              android:layout_height=&quot;32dp&quot;
              android:layout_marginStart=&quot;15dp&quot;
              android:layout_marginTop=&quot;100dp&quot;
              android:layout_marginEnd=&quot;16dp&quot;
              android:background=&quot;@color/tutorial_white_background&quot;
              android:padding=&quot;8dp&quot; /&gt;
  
          &lt;Button
              android:id=&quot;@+id/btnGoToWorkList&quot;
              android:layout_width=&quot;wrap_content&quot;
              android:layout_height=&quot;wrap_content&quot;
              android:layout_marginStart=&quot;100dp&quot;
              android:layout_marginEnd=&quot;100dp&quot;
              android:layout_marginBottom=&quot;100dp&quot;
              android:text=&quot;OK, TAKE ME TO WORK LIST&quot;
              app:layout_constraintBottom_toTopOf=&quot;@+id/tutorialDontShowAgain&quot;
              app:layout_constraintEnd_toEndOf=&quot;parent&quot;
              app:layout_constraintStart_toStartOf=&quot;parent&quot; /&gt;
      
          &lt;CheckBox
              android:id=&quot;@+id/tutorialDontShowAgain&quot;
              android:layout_width=&quot;wrap_content&quot;
              android:layout_height=&quot;wrap_content&quot;
              android:layout_margin=&quot;10dp&quot;
              android:buttonTint=&quot;@color/mdtp_white&quot;
              android:text=&quot;@string/tutorial_dont_show_again&quot;
              android:textColor=&quot;@color/mdtp_white&quot;
              app:layout_constraintBottom_toBottomOf=&quot;parent&quot;
              app:layout_constraintStart_toStartOf=&quot;parent&quot; /&gt;
  
      &lt;/androidx.constraintlayout.widget.ConstraintLayout&gt;
  
  &lt;/androidx.coordinatorlayout.widget.CoordinatorLayout&gt;
  </code></pre>
  <p><a href="https://i.stack.imgur.com/g4m1F.png" rel="nofollow noreferrer">Screen test</a></p>