Skip to content

Designer's "undo" for resize does not work correctly when there is anchored control #9218

@mocakturk

Description

@mocakturk

Environment

Microsoft Visual Studio Professional 2022 (64-bit) - Version 17.6.2

.NET version

.NET 7

Did this work in a previous version of Visual Studio and/or previous .NET release?

I was using .NET framework and Visual Studio 2017. There was no such problem.

Issue description

After clicking undo in designer for undoing a resize of a control, that "resize" is undone correctly. However, another anchored control is not undone correctly.
See the example below. Anchored textbox is not undone correctly.
anchor_undo_issue

Steps to reproduce

Create a Form.
Create a group-box. Add a textbox inside the groupbox. Anchor the textbox to groupbox.
Anchor the groupbox to form.
Then resize the form. Then click "undo". Notice that, textbox is not undone correctly.

Diagnostics

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-VSDesignerWindows Forms out-of-proc designer related issues

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions