Why ScrollView in .Net MAUI can not show its content

TD D 5 Reputation points
2023-09-13T14:29:51.87+00:00
in this code for example : <?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             xmlns:drawables="clr-namespace:GraphicsViewDemos.Drawables"
             x:Class="GraphicsViewDemos.Views.DrawShapesPage"
         
  
    <ScrollView>
        <VerticalStackLayout>
            <Label Text="Line" />
            <GraphicsView Drawable="{StaticResource lineDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Ellipse" />
            <GraphicsView Drawable="{StaticResource ellipseDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Filled ellipse" />
            <GraphicsView Drawable="{StaticResource filledEllipseDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Circle" />
            <GraphicsView Drawable="{StaticResource circleDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Rectangle" />
            <GraphicsView Drawable="{StaticResource rectangleDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Square" />
            <GraphicsView Drawable="{StaticResource squareDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Filled rectangle" />
            <GraphicsView Drawable="{StaticResource filledRectangleDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />
            <Label Text="Rounded rectangle" />
            <GraphicsView Drawable="{StaticResource roundedRectangleDrawable}"
                          HeightRequest="120"
                          WidthRequest="400" />   ...
                    </VerticalStackLayout>
    </ScrollView>
</ContentPage>, the total height of its shapes child elements exceeds the height of the 
Developer technologies | .NET | .NET MAUI
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.