Skip to content

Baseline SnapLines do not appear in DesignSurface #13305

Closed

Description

@jholcmanchyron

.NET version

9.0.4

Did it work in .NET Framework?

Yes

Did it work in any of the earlier releases of .NET Core or .NET 5+?

8.0.15

Issue description

After updating the runtime version from net8 to net9, the Baseline snap line (the purple one in the attached gif) stops appearing in the designer surface of a winforms app.

This is true for all controls I tried - Label, Button, CheckBox, DateTimePicker. I assume it is a general issue, not an issue with a specific control(s).

The other snap lines (Top, Bottom,...) are still working.

net8:
Image

net9:
Image

Steps to reproduce

Snaplinetest.zip

  1. Using the attached solution.
  2. Run SnaplinetestNet8
    a. The console output contains Baseline snap lines for both labels.
    b. The Baseline snap line (purple) appears when dragging one of the labels next to the other.
  3. Run SnaplinetestNet9
    a. The console output still contains Baseline snap lines for both labels, as it should...
    b. ... but the snap line does not appear when dragging the label.

Activity

  1. added
    untriagedThe team needs to look at this issue in the next triage
    on Apr 14, 2025
  2. merriemcgaw commented on Apr 14, 2025

    @merriemcgaw
    Contributor

    @jholcmanchyron we appreciate the minimum repro you provided, that should be helpful! I am curious as to your specific use case for the design surface. Are you creating a custom designer? Does this run in VS or standalone? This is something we could likely address in .NET 10, but to service back to 9 we'd need to know more about the customer impact.

  3. jholcmanchyron commented on Apr 15, 2025

    @jholcmanchyron
    Author

    @merriemcgaw We have a custom designer embedded in our application that allows our users to build custom panels containing a set of supported Winforms controls. They use the DesignSurface to drag these controls around, resize them and align them to their liking. Once they have that, they can "bind" those controls to certain functionality of the application (Button Clicks to execute some action, TextBox Text to appear somewhere, etc.). The final panel is then rendered in another part of the application to actually run the use case the user needs. I hope that clarifies it a bit, let me know if I can provide more to speed things up.

  4. merriemcgaw commented on Apr 15, 2025

    @merriemcgaw
    Contributor

    @LeafShi1 can you help us find where this regressed from 8 to 9 (and what is happening in 10)?

  5. added this to the .NET 10.0 milestone on Apr 15, 2025
  6. added theissue type on Apr 15, 2025
  7. added
    investigateItems we want to investigate before making a decision on an issue
    and removed
    untriagedThe team needs to look at this issue in the next triage
    on Apr 15, 2025
  8. 2 remaining items

  9. Tanya-Solyanik commented on Apr 18, 2025

    @Tanya-Solyanik
    Contributor

    @jholcmanchyron - we are fixing this issue in NET10. Do you require this fix in NET9, or do you have a workaround?

  10. added a commit that references this issue on Apr 21, 2025
    7098151
  11. jholcmanchyron commented on Apr 22, 2025

    @jholcmanchyron
    Author

    @Tanya-Solyanik I do not have any workarounds. If this could make it into net9, it would be nice. If there are any workarounds you or your team are aware of, please let me know.

  12. Tanya-Solyanik commented on Apr 22, 2025

    @Tanya-Solyanik
    Contributor

    @Epica3055 - could you please backport the fix and uniot test to release/9.0 as 2 separate commits and send this change to testing?

  13. added a commit that references this issue on Apr 23, 2025
    52584e7
  14. MelonWang1 commented on Apr 24, 2025

    @MelonWang1
    Contributor

    Verified in the latest .NET 10.0 SDK build: 10.0.100-preview.5.25223.16, it was fixed: Baseline snapshot lines are displayed in the design surface now.

    Image

    13305.mp4
  15. Syareel-Sukeri commented on May 7, 2025

    @Syareel-Sukeri
    Contributor

    Verified this issue in the .NET 10 Preview 4 test pass build, it was fixed. The test result is same as above

  16. added a commit that references this issue on May 8, 2025
    f8fd991
  17. Zheng-Li01 commented on May 15, 2025

    @Zheng-Li01
    Member

    Verified the issue with .NET SDK 9.0.5 + private build from release/9.0 branch of dotnet/winforms repro. it was fixed. The test result is same as above.

  18. MelonWang1 commented on May 22, 2025

    @MelonWang1
    Contributor

    Verified this issue in the .NET 9.0.6 test pass build, it was fixed, same result as above.

  19. locked and limited conversation to collaborators on Jun 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions