以下は、画面の下部にあるボタンに十分な大きさの小さな部分を除いて、画面全体を占めるスクロールビューを表示します。私がこれを実行すると、ボタン/レイアウトはまったく表示されません。私がスクロールビュー内に持っている他のビューで画面全体を占めるスクロールビューのみ。思考?スクロールビューの下の線画が表示されない
<LinearLayout android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
tools:context="com.th3ramr0d.armybodyfatcalculator.MainActivity"
android:orientation="vertical">
<ScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content">
</ScrollView>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Button 1"
/>
</LinearLayout>
</LinearLayout
このレイアウト作業のために仕事をしますが、私は私が依存のためにscrollviewの大きさを決定するために、デバイスをしたい、あなたのスクロールビュー – dex
に定義されたのmaxHeightに必要その下のレイアウトのサイズそれは可能ですか? – th3ramr0d
次に@Tiago Oliveiraの回答を – dex