title: How can I debug an Android style inheritance issue?
body: <p>When doing web development, you can inspect an element and see which classes provide which css rules. Is there an equivalent for Android development?</p>
  
  <p>TLDR; Here's an example of a style inheritance problem that I had and solved:</p>
  
  <p>I had a dialog has the Holo theme, but the text color was dark, even when I tried to set the text color to white.</p>
  
  <p>This is the dialog layout:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"&gt;
  
      &lt;ListView android:id="@android:id/list"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                style="@style/Theme.Dialog"/&gt;
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>In the <code>style.xml</code> resource:</p>
  
  <pre><code>&lt;style name="Theme.Dialog" parent="android:style/Theme.Holo.Dialog"&gt;
      &lt;item name="android:windowTitleStyle"&gt;@android:style/TextAppearance.Large&lt;/item&gt;
      &lt;item name="android:textColor"&gt;@color/solid_white&lt;/item&gt;
      &lt;item name="android:windowNoTitle"&gt;true&lt;/item&gt;
  &lt;/style&gt;
  </code></pre>
  
  <p>It turned out that I was using a <code>Fragment</code> whose <code>Activity</code> was a <code>ListActivity</code>, and it defined getView, which created the view from an xml style that set the text color to be dark. It would have liked to see what was setting the text color.</p>