<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="horizontal"
android:id="@+id/yourlayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<LinearLayout android:id="@+id/linearLayout1"
android:orientation="vertical"
android:layout_alignParentLeft="true"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<Button android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Button 1"
></Button>
</LinearLayout>
<LinearLayout android:id="@+id/linearLayout2"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_alignParentRight="true"
android:layout_height="fill_parent" >
<Button android:id="@+id/button2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Button 2"
></Button>
</LinearLayout>
</RelativeLayout>
И вы можете просто накачать этот макет, где вы хотите, и параметры, которые вы хотите.
LayoutInflater inflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE);
View v = inflater.inflate(R.layout.whereyouwant, null);
RelativeLayout rl = (RelativeLayout)findViewById(R.id.yourlayout);
RelativeLayout.LayoutParams parametri = new RelativeLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT);
parametri.addRule(RelativeLayout.ALIGN_PARENT_TOP);
rl.addView(v, parametri);
v.setVisibility(View.VISIBLE);