Programmatic RelativeLayout
<p>I'm attempting to programmatically add several Tiles which extend from TextViews into a RelativeLayout.</p>

<p>My code is as follows.</p>

<pre><code>    RelativeLayout.LayoutParams params = new RelativeLayout.LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT);

    for (int i = 0; i &lt; characters.length; i++) {
        Tile tile = new Tile(this);
        tile.setText(Character.toString(characters[i]));
        tile.setId(i);
        if (i != 0) {
            params.addRule(RelativeLayout.RIGHT_OF, i - 1);
        }
        _display.addView(tile, params);
    }
}
</code></pre>

<p>So I'm creating a new instance class of LayoutParams called params and adding a rule to align each tile to the right of the previous tile. When I run the app it appears that the tiles are just overlapping over each other. Any suggestions?</p>
