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 in application template, generic.xaml doesn't work out of the box #1699

Closed
weltkante opened this issue Aug 22, 2019 · 5 comments
Closed
Assignees
Labels
Bug Product bug (most likely) rank40 Rank: Priority/rank on a scale of (1..100) regression status: This issue is a regression from a previous build or release tenet-compatibility Incompatibility with previous versions or with WPF for .NET Framework
Milestone

Comments

@weltkante
Copy link

weltkante commented Aug 22, 2019

  • .NET Core Version: latest nightly (5.0.0-alpha1.19415.3)
  • Does the bug reproduce also in WPF for .NET Framework 4.8?: No

Problem description:
Creating a new WPF application for .NET Core the generic.xaml does not work out of the box when added manually (e.g. copy pasted from an existing project), it used to work on Desktop. It does work when using "new item" templates but since adding custom controls is just inheriting from a framework class it is often done without using the "new item" template and instead just writing code.

Actual behavior:
Creating a new application with the WPF for .NET Core template does not add a ThemeInfo attribute, I need to add a CustomControl template to get the attribute. This is a regression from Desktop Framework template behavior.

Expected behavior:
The WPF for .NET Core application template should already add the ThemeInfo attribute.

Minimal repro:

  • create a new WPF application for .NET Core
  • manually add code for a Custom Control and generic.xaml
@weltkante
Copy link
Author

weltkante commented Aug 22, 2019

Related issue #294 has been postponed to future, I want to point out above regression of the templates which can be confusing because generic.xaml doesn't work out of the box anymore when writing code manually. You might want to consider updating the templates for 3.0, though its a minor issue and I can understand if it doesn't meet the bar at this point.

@weltkante weltkante changed the title Regression in application template Regression in application template, generic.xaml doesn't work out of the box Aug 22, 2019
@grubioe grubioe added this to the 3.0 milestone Aug 22, 2019
@grubioe grubioe added the Bug Product bug (most likely) label Aug 22, 2019
@ryalanms
Copy link
Member

Discussed with @vatsan-madhavan: AssemblyInfo.cs with ThemeInfo should be added to the default WPF template.

@ryalanms ryalanms modified the milestones: 3.0, 3.1 Aug 22, 2019
@vatsan-madhavan
Copy link
Member

@weltkante we will likely fix this in 3.1.

If we already had an AssemblyInfo.cs for the application template, we'd have taken this for 3.0. Adding a new AssemblyInfo.cs and wiring it up is easy, but it also means spending some time testing it to make sure that an innocuous error didn't creep in and break something else. Rather do this in 3.1.

Since project templates can be consumed from a newer SDK while targeting netcoreapp3.0, and likewise VS can continue ingesting newer project templates while continuing to support netcoreapp3.0 targeting, this is not very critical to get in right-away.

@vatsan-madhavan vatsan-madhavan added regression status: This issue is a regression from a previous build or release tenet-compatibility Incompatibility with previous versions or with WPF for .NET Framework labels Aug 22, 2019
@grubioe grubioe added the rank40 Rank: Priority/rank on a scale of (1..100) label Aug 30, 2019
@grubioe grubioe assigned vatsan-madhavan and unassigned ryalanms Sep 12, 2019
@weltkante
Copy link
Author

Seems like #1966 is fallout from this regression.

@vatsan-madhavan
Copy link
Member

Application templates in .NET Core 3.1 and .NET Core 5.0 have been updated.

@ghost ghost locked as resolved and limited conversation to collaborators Apr 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Product bug (most likely) rank40 Rank: Priority/rank on a scale of (1..100) regression status: This issue is a regression from a previous build or release tenet-compatibility Incompatibility with previous versions or with WPF for .NET Framework
Projects
None yet
Development

No branches or pull requests

4 participants