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

Wrong rendering of Grid cell content #7122

Closed
Dokug opened this issue May 13, 2022 · 2 comments · Fixed by #7270
Closed

Wrong rendering of Grid cell content #7122

Dokug opened this issue May 13, 2022 · 2 comments · Fixed by #7270
Assignees
Labels
area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter fixed-in-6.0.400 Look for this fix in 6.0.400! platform/windows 🪟 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Milestone

Comments

@Dokug
Copy link

Dokug commented May 13, 2022

Description

When filling a 24x14 grid with a frame and a label for each cell, the label gets omitted on a semi-random basis as seen in the first picture.
When omitting the frames, all labels are shown, as seen in the second picture.
I have only tested this on Windows, not yet on any other platform.

I don't think this is expected behavior, but if it is, I apologize.

Best regards,
Dokug

image
image

Steps to Reproduce

  1. Create a File > New .NET MAUI App
  2. Replace the MainPage.xaml ContentPage Content with:
<Grid x:Name="ScreenGrid"
              RowDefinitions="*,*,*,*,*,*,*,*,*,*,*,*,*,*"
              ColumnDefinitions="*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*"/>
  1. In the MainPage.xaml.cs constructor add the following:
for (int row = 0; row < ScreenGrid.RowDefinitions.Count; row++)
{
    for (int col = 0; col < ScreenGrid.ColumnDefinitions.Count; col++)
    {
        Label label = new Label
        {
            Text = "A"
        };

        ScreenGrid.Add(new Frame(), col, row);
        ScreenGrid.Add(label, col, row);
    }
}
  1. Run the app to see the missing labels
  2. Comment out the line adding the frames to the ScreenGrid to see the difference

Version with bug

Release Candidate 3 (current)

Last version that worked well

Unknown/Other

Affected platforms

Windows, I was not able test on other platforms

Affected platform versions

Windows SDK 10.0.17134.0

Did you find any workaround?

No response

Relevant log output

No response

@Dokug Dokug added s/needs-verification Indicates that this issue needs initial verification before further triage will happen t/bug Something isn't working labels May 13, 2022
@Dokug Dokug changed the title Wrong rendering of Grid Wrong rendering of Grid Cells May 13, 2022
@Dokug Dokug changed the title Wrong rendering of Grid Cells Wrong rendering of Grid cell content May 13, 2022
@v-longmin v-longmin added s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage labels May 13, 2022
@v-longmin
Copy link

Verified repro on Windows10 with VS 17.3.0 Preview 1.0 [32427.505.main]. Repro with above project.

@v-longmin v-longmin removed the s/needs-verification Indicates that this issue needs initial verification before further triage will happen label May 13, 2022
@hartez hartez self-assigned this May 13, 2022
@hartez hartez added this to the 6.0.300-servicing milestone May 13, 2022
@Eilon Eilon added the area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter label May 13, 2022
@hartez
Copy link
Contributor

hartez commented May 17, 2022

If you're looking for a workaround until we get this fixed, you can add label.ZIndex = 10; to force the Labels to have a higher z-index than the Frames; that will prevent the Labels from being hidden.

@ghost ghost locked as resolved and limited conversation to collaborators Jun 17, 2022
@samhouts samhouts added the fixed-in-6.0.400 Look for this fix in 6.0.400! label Feb 17, 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-6.0.400 Look for this fix in 6.0.400! platform/windows 🪟 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants