title: Unexpected results for android xml layout
body: <p>I'm beginner in android development and often have received the strange results. Below is markup where I expect to see red and green sequential rectangles. But really I see only green area:</p>
  <p><a href="https://i.stack.imgur.com/qNBU9.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qNBU9.png" alt="enter image description here" /></a></p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;
  &lt;FrameLayout xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
      xmlns:app=&quot;http://schemas.android.com/apk/res-auto&quot;
      android:layout_width=&quot;200dp&quot;
      android:layout_height=&quot;100dp&quot;&gt;
  
      &lt;androidx.constraintlayout.widget.ConstraintLayout
          android:id=&quot;@+id/first_constrain&quot;
          android:layout_width=&quot;100dp&quot;
          android:layout_height=&quot;match_parent&quot;
          app:layout_constraintStart_toStartOf=&quot;parent&quot;
          app:layout_constraintTop_toTopOf=&quot;parent&quot;
          app:layout_constraintBottom_toBottomOf=&quot;parent&quot;
          android:background=&quot;#FF0000&quot; /&gt;
  
      &lt;androidx.constraintlayout.widget.ConstraintLayout
          android:id=&quot;@+id/second_constrain&quot;
          android:layout_width=&quot;100dp&quot;
          android:layout_height=&quot;match_parent&quot;
          app:layout_constraintStart_toEndOf=&quot;@+id/first_constrain&quot;
          app:layout_constraintEnd_toEndOf=&quot;parent&quot;
          app:layout_constraintTop_toTopOf=&quot;parent&quot;
          app:layout_constraintBottom_toBottomOf=&quot;parent&quot;
          android:background=&quot;#00FF00&quot;&gt;
  
      &lt;/androidx.constraintlayout.widget.ConstraintLayout&gt;
  &lt;/FrameLayout&gt;
  </code></pre>
  <p>Please explain what is wrong in my code.</p>