title: PreferenceFragment is shown transparently
body: <p>I'm trying to show a <code>PreferenceFragment</code> after I select the Preferences option in my ActionBar.
  However, after replacing current content with the <code>PreferenceFragment</code> you can see the old content below it. As in, you can see straight through the preferences.</p>
  
  <p>Am I missing something here? I used an example from a book I own, which didn't use any layout files for the preferences. Do you need those?</p>
  
  <p><strong>Used code:</strong></p>
  
  <p>Actionbar menu</p>
  
  <pre><code>private boolean MenuChoice(MenuItem item) {
          switch (item.getItemId()) {
          case 0:
              FragmentManager fragmentManager = getFragmentManager();
              FragmentTransaction fragmentTransaction =
              fragmentManager.beginTransaction();
              ReaderPreferences prefs = new ReaderPreferences();
              fragmentTransaction.replace(android.R.id.content, prefs);
              fragmentTransaction.addToBackStack(null);
              fragmentTransaction.commit();
              return true;
  
          }
          return false;
      }
  </code></pre>
  
  <p>PreferenceReader</p>
  
  <pre><code>public class ReaderPreferences extends PreferenceFragment {
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          // --load the preferences from an XML file---
          addPreferencesFromResource(R.xml.preference);
      }
    }
  </code></pre>
  
  <p><strong>Actual result:</strong></p>
  
  <p><img src="https://i.stack.imgur.com/WPtdo.png" alt="enter image description here"></p>
  
  <p>As you can see, you look straight through my preferences. 
  What did I do wrong?</p>