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

Border control is not updated, while it's width and height changed. #5464

Closed
Sasikumar3595 opened this issue Mar 21, 2022 · 2 comments · Fixed by #5608
Closed

Border control is not updated, while it's width and height changed. #5464

Sasikumar3595 opened this issue Mar 21, 2022 · 2 comments · Fixed by #5608
Assignees
Labels
area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter fixed-in-6.0.300-rc.1 Look for this fix in 6.0.300-rc.1! high It doesn't work at all, crashes or has a big impact. platform/android 🤖 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Milestone

Comments

@Sasikumar3595
Copy link

Description

We have created the application with border control and the border control was not updated size (width/height) while changing the border size (width/height)


        StackLayout customControlStack = new StackLayout();
        for (int i = 0; i < 10; i++)
        {
            Border border = new Border();
            border.Stroke = Colors.Red;
            border.StrokeThickness = 2;
            border.Margin = new Thickness(1);
            border.Padding = new Thickness(2);
            border.StrokeShape = new Microsoft.Maui.Controls.Shapes.RoundRectangle()
            {
                CornerRadius = 5
            };
            Label label = new Label();
            label.Text = i.ToString();
            label.HeightRequest = 50;
            border.Content = label;
            customControlStack.Add(border);
        }
        customControlStack.WidthRequest = 300;
        TapGestureRecognizer customTap = new TapGestureRecognizer();
        customTap.Tapped += (s, e) =>
        {
            customControlStack.WidthRequest = customControlStack.WidthRequest - 10;
        };
        customControlStack.GestureRecognizers.Add(customTap);
        this.Content = customControlStack;

Initial UI:

InitialUI

After resized UI:

Issue

Replication video:

Replication.mp4

Steps to Reproduce

  1. Create a sample with the above code
  2. Tap the stack layout to reduce its width value
  3. Border was not resized with it updated size

Version with bug

Preview 14 (current)

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 10

Did you find any workaround?

No

Relevant log output

Not Applicable
@Sasikumar3595 Sasikumar3595 added s/needs-verification Indicates that this issue needs initial verification before further triage will happen t/bug Something isn't working labels Mar 21, 2022
@jsuarezruiz jsuarezruiz added high It doesn't work at all, crashes or has a big impact. area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter labels Mar 21, 2022
@jfversluis jfversluis added platform/android 🤖 and removed s/needs-verification Indicates that this issue needs initial verification before further triage will happen labels Mar 21, 2022
@XamlTest XamlTest added the s/triaged Issue has been reviewed label Mar 22, 2022
@shimingsg
Copy link

verified repro with VS 17.2.0 Preview 3.0 [32317.342.main] on Android 10 with above code snippet

@shimingsg shimingsg added the s/verified Verified / Reproducible Issue ready for Engineering Triage label Mar 22, 2022
@XamlTest
Copy link

This issue not repro on Windows and iOS. Sample Project: 5464.zip

@hartez hartez added this to the 6.0.300-servicing milestone Mar 22, 2022
@Redth Redth modified the milestones: 6.0.300-servicing, 6.0.300-rc.2 Mar 23, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Apr 27, 2022
@samhouts samhouts added the fixed-in-6.0.300-rc.1 Look for this fix in 6.0.300-rc.1! 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.300-rc.1 Look for this fix in 6.0.300-rc.1! high It doesn't work at all, crashes or has a big impact. platform/android 🤖 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.

8 participants