title: How to make Edittext size stay put? Android
body: <p>I know the attribute which makes the text "disapear" on the left part of the Edittext to maintain a single line, (singleLine="true"). But my issue is when I fill the edittext before the view is displayed... in this case, my edittexts are all going out of the screen...
  any ideas?
  thx!</p>
  
  <p>This is what is get when fill the empty Edittext. Everything stays put, and the text is vanishing on its left side</p>
  
  <p><a href="http://www.freeimagehosting.net/image.php?1f6d9de832.png" rel="nofollow noreferrer">Screenshot</a></p>
  
  <p>and when I prefill from my DB</p>
  
  <p><a href="http://www.freeimagehosting.net/image.php?87a63b1b21.png" rel="nofollow noreferrer">Screenshot</a></p>
  
  <p>here is the code of the edittext :</p>
  
  <pre><code>&lt;EditText android:id="@+id/InscripChampNom"
  android:layout_height="wrap_content" android:textSize="14px"
  android:inputType="textPersonName" android:layout_marginRight="20dip"
  android:singleLine="true" android:textColor="@color/background"&gt;&lt;/EditText&gt;
  </code></pre>
  
  <p>The tableLayout is defined as follows:</p>
  
  <pre><code>&lt;TableLayout android:layout_width="fill_parent"
  android:stretchColumns="1" android:layout_height="fill_parent"&gt;
  </code></pre>
  
  <p>I also tried with the attribute </p>
  
  <pre><code>android:layout_width="fill_parent"
  </code></pre>
  
  <p>and</p>
  
  <pre><code>android:layout_width="wrap_content"
  </code></pre>
  
  <p>no success at all...</p>
  
  <p>Maybe there is a conflict between input type and singleline?</p>
  
  <p><strong>EDIT  Here is the full code of my issue :</strong>  </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
  android:scrollbars="vertical" android:background="@color/backgroundzen"
  android:layout_gravity="fill" android:layout_height="fill_parent"
  android:layout_width="fill_parent" android:paddingLeft="6dip"
  android:paddingRight="6dip"&gt;
  &lt;TableLayout style="@style/LayoutWhiteBgrdFillWrap"
      android:paddingLeft="6dip" android:paddingRight="6dip"
      android:stretchColumns="1"&gt;
      &lt;TextView android:id="@+id/NomFormationConference" style="@style/textViewTitleRedzenBold"
          android:text="Nom conférence"&gt;&lt;/TextView&gt;
      &lt;TableRow android:layout_margin="2dip"&gt;
          &lt;TextView android:id="@+id/DateSession" android:textColor="@color/textezenrouge"
              android:layout_height="wrap_content" android:layout_width="wrap_content"
              android:text="date début"&gt;&lt;/TextView&gt;
          &lt;TextView android:id="@+id/speakerConf" android:textColor="@color/textezenrouge"
              android:layout_height="wrap_content" android:layout_width="wrap_content"
              android:text="speaker"&gt;&lt;/TextView&gt;
      &lt;/TableRow&gt;
      &lt;TableRow android:layout_margin="2dip"&gt;
          &lt;TextView android:id="@+id/InscripNom" android:layout_width="wrap_content"
              android:textColor="@color/background" android:layout_height="wrap_content"
              android:text="@string/nom" android:textStyle="bold"&gt;&lt;/TextView&gt;
          &lt;EditText android:id="@+id/InscripChampNom"
              android:layout_height="wrap_content" android:textSize="14sp"
              android:layout_width="fill_parent" android:inputType="textPersonName"
              android:layout_marginRight="20dip" android:hint="@string/nomh"
              android:singleLine="true" android:textColor="@color/background"&gt;&lt;/EditText&gt;
      &lt;/TableRow&gt;
  </code></pre>
  
  <p>//The last tablerow is repeated 5 times with various data inside.
      
      </p>
  
  <p>The style is like that :  </p>
  
  <pre><code>&lt;style name="LayoutWhiteBgrdFillWrap"&gt;
      &lt;item name="android:background"&gt;@color/backgroundzen&lt;/item&gt;
      &lt;item name="android:layout_width"&gt;fill_parent&lt;/item&gt;
      &lt;item name="android:layout_height"&gt;fill_parent&lt;/item&gt;
  &lt;/style&gt;
  </code></pre>
  
  <p>And here is how I fill the <code>EditText</code> :  </p>
  
  <pre><code>misc = SQLiteDatabase.openDatabase("/data/data/com.mobile.zen/databases/" + Constants.UNVERSIONNED_DATABASE, null,
              SQLiteDatabase.OPEN_READONLY);
      Cursor c = misc.query("MISC", null, null, null, null, null, null);
      if (c.moveToFirst()) {
          do {
              nomInscrit.setText(c.getString(1));
          } while (c.moveToNext());
      }
      c.close();
      misc.close();
  </code></pre>