Android 当内容大小超过屏幕大小时,scrollview不垂直增长

Android 当内容大小超过屏幕大小时,scrollview不垂直增长,android,android-layout,Android,Android Layout,使用上述layout.xml,当ID为linearLayout1和linearLayout2的线性布局的内容垂直增大时,不会显示代码滚动条 当linearLayout1和linearLayout2的大小超过父级大小时,请建议如何在活动视图中显示滚动条。我希望完整的“活动”视图只有一个滚动条,而不是线性布局1和线性布局2的单独滚动条。滚动视图也应具有包装内容的布局高度 所有布局高度换行内容?不显示是什么意思?@mvai线性布局linearLayout1和linearLayout2从不超出父级高度,

使用上述layout.xml,当ID为linearLayout1和linearLayout2的线性布局的内容垂直增大时,不会显示代码滚动条


当linearLayout1和linearLayout2的大小超过父级大小时,请建议如何在活动视图中显示滚动条。我希望完整的“活动”视图只有一个滚动条,而不是线性布局1和线性布局2的单独滚动条。

滚动视图也应具有包装内容的布局高度

所有布局高度换行内容?不显示是什么意思?@mvai线性布局linearLayout1和linearLayout2从不超出父级高度,因此滚动条从不显示。如果线性布局不够大,为什么要显示它?给一个非常大的高度值,你的滚动条就会出现。我正在动态地将带有片段的framelayouts添加到linearLayout1和linearLayout2中,我预计当所有framelayouts的总大小超过屏幕高度时,滚动条就会出现。
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/notesLayoutManagerScrollView"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="#fffaaa"
    android:fillViewport="true"
    tools:context="com.gp.app.professionalpa.layout.manager.NotesLayoutManagerActivity">

<LinearLayout 
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:id="@+id/notesLayoutManagerParentLinearLayout"
    android:orientation="horizontal"
    android:background="#ffffff"
    android:baselineAligned="false">

    <LinearLayout
        android:id="@+id/linearLayout1"
        android:layout_width="0dip"
        android:layout_height="match_parent"
        android:orientation="vertical"
        android:layout_weight="1"
        android:layout_marginRight="1dip"
        android:background="#ffffff">
    </LinearLayout>

    <LinearLayout
        android:id="@+id/linearLayout2"
        android:layout_width="0dip"
        android:layout_height="match_parent"
        android:orientation="vertical"
        android:layout_weight="1"
        android:layout_marginLeft="1dip"
        android:background="#ffffff">
    </LinearLayout>
</LinearLayout>
</ScrollView>