Showing posts with label UI design. Show all posts
Showing posts with label UI design. Show all posts

Monday, 23 January 2012

C# - Dynamically skinning your WPF applications

Far from making suggestions about how to inflict great pain and suffering on your WPF applications, this should make your applications that little bit more interactive and customisable. The way we'll be doing this is by dynamically loading in resource dictionaries into the Application's merged dictionaries. Lost? Don't worry, I was at first too. I'll elaborate what I know further down.

These methods are rather generic (in a non object-oriented way), but are set up to read through an application's subdirectory called 'Skins' and return all the skins into functional menuitems which will be put into a menu called themes. Change and adjust as necessary.