dotnet / dotnet/wpf

Themebuilder for WPF

Open
#7,649 6 comments 3 reactions 0 assignees View on GitHub
Enhancement Requested
Dominant language
C#
Stars
7.7k
Forks
1.3k
Avg merge
1d 11h
Merged PRs (30d)
61

Description

@pchaurasia14 Here is the post about a potential Theme Builder that we discussed earlier. So this is to build on our last talks about the WPF Roadmap and where all the votes landed, etc. For those that are coming late to the party, that discussion can be found [here](https://github.com/dotnet/wpf/blob/main/roadmap.md#modernizing-wpf:~:text=releases%20of%20.NET.-,Modernizing%20WPF,-Long%2Dterm%20vision).

So when we are talking about bringing the Windows 11 look and feel to wpf controls, I think it should be pointed out that the community has never really had a way to get the most up-to-date look and feel on the desktop controls. But this was supposed to be one of the key reasons that WPF was so big. It allows the user to make any control look however they want it to look. The sky is the limit... So we of course know that the 3rd party control suite providers offer all kinds of themes. And for a couple thousand dollars a year, you too, could own a set of controls with outstanding themes... The problem is, alot of companies cant afford a couple thousand dollars a year just to buy controls that "look" nice. There has to be functionality as well. And that functionality must be quantified. Anyway, so I had brought up the point that one of the 3rd party control suite vendors started selling their THEME BUILDER application for like $100 bucks per license. Which I immediately had words with several of the people that thought that was a good idea. The company I was representing had been paying for the most expensive package that they could get for almost a decade. And by the time it was said and done, the vendor offered ME and only ME, the Theme Builder at no extra charge, which I quickly declined to accept because it was the sheer principal of the matter... and giving it to me for free doesnt help all the other people that they are nickle and diming for a generated, glorified style sheet.

Which brings me full circle... The Wpf controls have always had some themes and styles like Aero and Aero Black, and most of the time they existed in sample apps or demos, and you could grab the generic.xaml file and do some modding and VOILA you have a new style dictionary. One of my favorites was the wireframing sketch controls and styles that came with Blend a LOOONG TIME AGO. I have sense dug all that stuff out and resurrected an app using the sketch styles and fonts. So My proposal is this. And please this is all just rolling off the tongue, so if anyone has any ideas to facilitate this or explain it better, by all means, please do so....But the talks we were involved in revolved around Windows 11. And some of the stuff that's going to be done will not be backported unfortunately. SO why not try to gather up all these older style dictionaries and present them in a Microsoft Branded Theme Builder for the ages. A gift for the community that has been using WPF since before its first Release Candidate. A way to make their applications reflect the time and energy they put into the functionality of the apps. Oh what a treat, not only is my app solid as a rock, but it looks AWESOME TOO! The biggest and baddest collection of resource dictionaries and styles that the community has ever seen. And it can even be powered by the community, if we implemented a way to share our styles and themes with the community at large.

So, ay I needed a nice looking style but Im still using .Net 4.6.x Well I would select my .Net Version and there could be a list of all the different styles or resource dictionaries that were released in demos or examples when that framework was released, etc.... but why stop there. We can parse the dictionaries for the most common properties and normalize the naming conventions on them so that we have like a common set of Brushes for the framework in question.... Like ya know AccentBrush or PrimaryBrush, HighlightBrush, DisabledBrush, etc....and have it to where you can select a dark-themed version or a light themed version. Have it to where you can select a primary color and the theme builder could run a few algorithms to get some awesome swatches in your "theme". So this would satisfy all the people that are still using the older frameworks, but all the while, we are building this Theme Builder for the future. well we're building it for Windows 11, which is kinda the present, and will quickly be the past, but we are also building it so that it can be built upon . So it can grow. It will grow with each operating system, and it can grow in the context of supported frameworks, and it can be easily adapted to Maui, and like I said I think the sky is the limit if we just put some thought into this...So....what say you

Here is one of my apps I use to save Color Palettes, and allows me to give each swatch a name like AccentFocusedColor. I havent used this app in a while but could be quickly repurposed to generate the styles needed for a nicely themed application. It also allows you to upload an image and will give you the predominant colors in the image but will also give you any number of swatches you want back based on the percentages of each color in the photo

![image](https://user-images.githubusercontent.com/112649342/226491287-ea00bcef-7469-49ed-b29a-5838364ed8a7.png)

Here is the app that came out of getting all the old prototyping sketch styles out of blend and repurposing them in my own prototyping app .

![image](https://user-images.githubusercontent.com/112649342/226494040-a1b2d7dd-23d7-4ebb-bff9-8e29ca626aaa.png)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.