title: CardView rounded corners not showing up in Android preview
body: <h2>My problem</h2>
  
  <p>My card views defined through XML are <strong>not showing their proper rounded corners (they are being covered by its subviews) in Android studio preview</strong>. </p>
  
  <p><strong>Although it shows up fine after rendering in the simulator</strong>, I fear that this "glitch" may be a symptom of me doing something wrong or forgetting some critical attribute. And even if it wasn't a symptom of a deeper problem, could anyone offer any insight on how to fix this aesthetic error?</p>
  
  <p>Could anyone weigh in on this?</p>
  
  <pre><code>&lt;android.support.v7.widget.CardView
      android:layout_marginTop="16dp"
      android:layout_marginStart="16dp"
      android:layout_marginEnd="16dp"
      android:layout_marginBottom="16dp"
  
      app:cardCornerRadius="10dp"
  
      android:layout_width="match_parent"
      android:layout_height="match_parent"&gt;
  
      &lt;android.support.v7.widget.AppCompatImageView
          android:src="@color/red"
          android:layout_width="match_parent"
          android:layout_height="match_parent"/&gt;
  
  &lt;/android.support.v7.widget.CardView&gt;
  </code></pre>
  
  <h2>Android studio screenshot</h2>
  
  <p><a href="https://i.stack.imgur.com/SVKdrm.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SVKdrm.png" alt="enter image description here"></a></p>
  
  <h2>Android emulator screenshot</h2>
  
  <p><a href="https://i.stack.imgur.com/IpaZum.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/IpaZum.png" alt="enter image description here"></a></p>