Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[regression/8.0.0-preview.5.8529] - Grid Columns Not Resizing Correctly (WinUI/MacCatalyst) #15905

Closed
TiberiusDRAIG opened this issue Jun 28, 2023 · 2 comments
Labels
area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter fixed-in-7.0.92 Look for this fix in 7.0.92! fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! fixed-in-7.0.100 fixed-in-7.0.101 i/regression This issue described a confirmed regression on a currently supported version s/duplicate 2️⃣ This issue or pull request already exists t/bug Something isn't working

Comments

@TiberiusDRAIG
Copy link

TiberiusDRAIG commented Jun 28, 2023

Description

Grid column resizing is not behaving as expected in .NET8 Preview 5 - I'm finding that things spanning multiple columns can get pushed off the screen at certain sizes, then seem to slide back into view:

weirdGrid.webm

This doesn't seem to be view-dependent - in our actual app (the above is a simpler repro) we're having the issue using a DockLayout as the multi-column spanning layout.

Steps to Reproduce

  1. Create default MAUI template app
  2. Update MainPage.xaml to:
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             x:Class="MauiApp1.MainPage">

    <Grid ColumnDefinitions="3*,*"
          RowDefinitions="*,Auto">
        <VerticalStackLayout
            Spacing="25"
            Padding="30,0"
            VerticalOptions="Center"
            Grid.Column="0"
            Grid.Row="0">

            <Image
                Source="dotnet_bot.png"
                SemanticProperties.Description="Cute dot net bot waving hi to you!"
                HeightRequest="200"
                HorizontalOptions="Center" />

            <Label
                Text="Hello, World!"
                SemanticProperties.HeadingLevel="Level1"
                FontSize="32"
                HorizontalOptions="Center" />

            <Label
                Text="Welcome to .NET Multi-platform App UI"
                SemanticProperties.HeadingLevel="Level2"
                SemanticProperties.Description="Welcome to dot net Multi platform App U I"
                FontSize="18"
                HorizontalOptions="Center" />

            <Button
                x:Name="CounterBtn"
                Text="Click me"
                SemanticProperties.Hint="Counts the number of times you click"
                Clicked="OnCounterClicked"
                HorizontalOptions="Center" />

        </VerticalStackLayout>
        <HorizontalStackLayout Grid.Row="1"
                               Grid.Column="0"
                               Grid.ColumnSpan="2"
                               HeightRequest="80"
                               HorizontalOptions="End"
                               Padding="10"
                               Background="Red">
            <Button/>
            <Button/>
            <Button/>
            <Button/>
        </HorizontalStackLayout>
    </Grid>

</ContentPage>
  1. Resize window horizontally and observe weird clipping.

Link to public reproduction project repository

https://github.com/TiberiusDRAIG/MauiGridResizeBug

Version with bug

8.0.0-preview.5.8529

Last version that worked well

7.0.86

Affected platforms

I was not able test on other platforms

Affected platform versions

net8.0-windows10.0.19041.0

Did you find any workaround?

No workarounds other than completely redesigning views.

Relevant log output

No response

@TiberiusDRAIG TiberiusDRAIG added the t/bug Something isn't working label Jun 28, 2023
@TiberiusDRAIG
Copy link
Author

Reproduced on Catalyst:

catalystRepro.mov

@TiberiusDRAIG TiberiusDRAIG changed the title [Regression] - Grid Columns Not Resizing Correctly (WinUI) [Regression] - Grid Columns Not Resizing Correctly (WinUI/MacCatalyst) Jun 28, 2023
@Eilon Eilon added the area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter label Jun 28, 2023
@PureWeen
Copy link
Member

Duplicate of #15793

@PureWeen PureWeen marked this as a duplicate of #15793 Jun 28, 2023
@samhouts samhouts added the i/regression This issue described a confirmed regression on a currently supported version label Jun 29, 2023
@samhouts samhouts changed the title [Regression] - Grid Columns Not Resizing Correctly (WinUI/MacCatalyst) [regression/8.0.0-preview.5.8529] - Grid Columns Not Resizing Correctly (WinUI/MacCatalyst) Jun 29, 2023
@samhouts samhouts added this to the .NET 8 milestone Jun 29, 2023
@samhouts samhouts added the s/duplicate 2️⃣ This issue or pull request already exists label Jun 29, 2023
@samhouts samhouts modified the milestones: .NET 8, .NET 7 + Servicing Jul 10, 2023
@samhouts samhouts added the fixed-in-7.0.92 Look for this fix in 7.0.92! label Jul 11, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Sep 8, 2023
@samhouts samhouts added the fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! label Oct 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter fixed-in-7.0.92 Look for this fix in 7.0.92! fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! fixed-in-7.0.100 fixed-in-7.0.101 i/regression This issue described a confirmed regression on a currently supported version s/duplicate 2️⃣ This issue or pull request already exists t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants