私はXMLファイル内にボタンを静的に宣言したテーブルレイアウトを持っています。プログラムに動的に行を追加します。私はボタンをテーブルレイアウトの最後に設定したい。 私はアンドロイド:layout_gravity = "bottom"を使ってそれを試みましたが、それは助けにはなりません。レイアウトの一番下にボタンを設定する - Android 2.2
すべてのソリューションはありますか?
これは私がすべての子を削除し、適切な順序でそれらをreaddingずにViewGroup
の子どもたちを並べ替えする方法があります信じていない私のXML
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:scrollbars="horizontal|vertical"
android:scrollbarStyle="outsideInset" >
<TableLayout
android:id="@+id/table"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Button
android:id="@+id/back"
android:layout_gravity="bottom"
/>
</TableLayout>
</ScrollView>
スクロールビューの下に意味あなたの親のレイアウト –
ScrollViewは何ですか。私はそれが重要ではないと思う。それでも。 – CamelCase
xmlファイルを投稿できますか?スクロール表示の場合、レイアウトを変更する必要がありますか? –