How to scale a View without it moving X, Y position?
<p>I have a <code>RadioGroup</code> that I'm trying to scale down because it's too big. So I use <code>setScaleX()</code> and <code>setScaleY()</code> and scale it down. </p>

<p>It works but the problem is that the View changes X and Y position when I scale it. I want it to keep the same top left coordinate after scaling. How to make the View stay put after scaling?  </p>

<p>See code below:</p>

<pre><code>CSRadioButton radiobutton = (CSRadioButton) field;
RadioGroup rg = new RadioGroup(this);
rg.setOrientation(RadioGroup.VERTICAL);
JSONArray choices = radiobutton.getChoices();
for(int j = 0; j &lt; choices.length(); j++){
    JSONObject currObj = choices.getJSONObject(j);
    String text = currObj.getString("text");
    RadioButton rb = new RadioButton(this);
    rb.setText(text);
    rg.addView(rb);
}

rscroll.addView(rg, lp);

rg.setScaleX(0.7f);
rg.setScaleY(0.7f); 
</code></pre>