title: How to center a two-line text in a TextView on Android?
body: <p>I want to let it looks like this:</p>
  
  <pre><code>|    two    |
  |   lines   |
  </code></pre>
  
  <p>Here is the current layout, not working at all.</p>
  
  <pre><code>&lt;RelativeLayout
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:gravity="center_vertical"&gt;
      &lt;TextView
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="two\nlines"
          android:layout_gravity="center_vertical"
          android:layout_centerInParent="true"/&gt;
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>Any idea?
  Thanks!</p>