How to change the weight size of a fragment in android?
<p>Here is the xml-Layout of my fragment view</p>

<pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:orientation="horizontal"
    android:weightSum="100"
     &gt;

    &lt;fragment
        android:id="@+id/menuFragment"
        android:layout_width="fill_parent"
        android:layout_height="match_parent"
        android:layout_weight="70"

        class="com.pack.Menufragment" &gt;
    &lt;/fragment&gt;

    &lt;fragment
        android:id="@+id/bodyFragment"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_weight="30"
        class="com.pack.BodyFragment" &gt;
    &lt;/fragment&gt;

&lt;/LinearLayout&gt;
</code></pre>

<p>Now I want to change the fragment weight size from the java not from XML, is there anyway to do this?</p>
