MaterialDesignInXamlToolkit README

The project's README from github.com/MaterialDesignInXAML/MaterialDesignInXamlToolkit. As one markdown file: README.md.

Material Design In XAML Toolkit Logo of Material Design in XAML

NuGet-Themes NuGet-Colors

NuGet-Themes-CI NuGet-Colors-CI

Backers on Open Collective Sponsors on Open Collective Chat Issues

Comprehensive and easy to use Material Design theme and control library for the Windows desktop (WPF).

See screenshots

Table of contents

Getting started

[!NOTE] See the full starting guide for more in-depth information.

This quick guide assumes you have already created a WPF project and are using Microsoft Visual Studio 2022.

Install-Package MaterialDesignThemes
<Application 
  x:Class="Example.App"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
  StartupUri="MainWindow.xaml">
    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <materialDesign:BundledTheme BaseTheme="Light" PrimaryColor="DeepPurple" SecondaryColor="Lime" />

                <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign2.Defaults.xaml" /> 
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>
<Window [...]
  Style="{StaticResource MaterialDesignWindow}"
  [...] >

XML Namespaces

The toolkit exposes two XML namespaces for use in XAML:

Prefix URI Description
materialDesign http://materialdesigninxaml.net/winfx/xaml/themes Primary namespace for all public Material Design types, controls, and converters.
materialDesignInternal http://materialdesigninxaml.net/winfx/xaml/themes-internal Namespace for types in internal sub-namespaces (MaterialDesignThemes.Wpf.Internal, MaterialDesignThemes.Wpf.Converters.Internal, MaterialDesignThemes.Wpf.Behaviors.Internal).

[!WARNING] Types exposed via the materialDesignInternal namespace are considered internal implementation details and are not guaranteed to maintain backwards-compatibility between versions. Use them at your own risk.

To use the internal namespace in XAML:

<Window ...
  xmlns:materialDesignInternal="http://materialdesigninxaml.net/winfx/xaml/themes-internal">

Building the source

To build the project, following is required:

This repository also contains 3 different demo applications:

Screenshots

Material Design 3 demo app screenshots

Buttons Cards Chips Colortool Colorzones Comboboxes Datagrids Dialogs Drawer Elevation Expander Fields Fieldslineup Groupboxes Home Iconpack Lists Menustoolbars Navigationbar Navigationrail Pallete Pickers Progressindicators Ratingbar Slider Snackbar Toggles Tooltips Transitions Trees Typography

Material Design 2 demo app screenshots

[!WARNING] The screenshots below are taken from the Material Design 2 demo app. Material Design 3 is the latest version, so the UI shown here may differ from the latest design.

Screenshot of WPF Material Design 2 demo application home page Buttons Toggles Fields ComboBoxes Palette Color Tools Pickers Icons Cards Menus and Toolbars Progress Bars Dialogs Lists Tree View Sliders Chips Typography Group Box Snackbars Elevation Colorzones Datagrids Drawer Expander Fieldslineup Navigationrail NumericUpDown Ratingbar Tabs Tooltips Transitions

More examples

FAQ

Contributing

Before contributing code read the Contribution Guidelines

Want to say thanks? 🙏🏻

This project exists thanks to all the people who contribute.

Mentions

Backers

Thank you to all our backers! 🙏 Become a backer.

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. Become a sponsor.

MaterialDesignInXamlToolkit (MaterialDesignInXAML/MaterialDesignInXamlToolkit)

Searching Database…

What is this?Google's Material Design brought to WPF: an open-source theme and control library for Windows desktop apps written in C# or VB.Net. It restyles all major WPF controls and adds Material-flavored extras.
So is it an app I install, or something I add to my own project?A library, not an app: you reference it from an existing WPF project, and it applies Material Design styling to the controls you already use, plus ships some of its own.
How do I add it to a WPF project?Install the toolkit via Visual Studio's NuGet package manager or the command line, then alter App.xaml (and MainWindow.xaml) per the getting-started guide. To target Material Design 3, use MaterialDesign3.Defaults.xaml.
What do I need to have installed before starting?A WPF project and Visual Studio 2022. If you want to build the toolkit's source yourself, you additionally need the .NET desktop development workload.
Is Material Design 3 support fully ready yet?You can already target MD3 via MaterialDesign3.Defaults.xaml, but its dedicated demo app is still under development — the Material Design 2 demo remains the complete reference containing all controls.
Is this Windows-only, or can I use it for Mac or Linux apps too?Windows-only — it targets WPF, the Windows desktop framework, so macOS and Linux are out of scope.
Which extra controls does it add beyond the styled WPF ones?Cards, Dialogs, a Clock and a Multi Action Button, plus the full Material Design Icons icon pack and easy transition effects.
Can I change the color scheme while the app is running?Yes — the palette is easy to configure both at design time and at runtime, following Google's Material Design guidelines.
Does it get along with other WPF UI libraries?Yes — it's compatible with Dragablz and MahApps, and the repo even ships a demo combining the three. Under the hood it builds on the ControlzEx library.
Can I see what the controls look like before adopting it?Yes — the source project includes demo applications: MaterialDesignDemo (Material Design 2 styling, all controls, a recommended tool while developing) and MaterialDesign3Demo for the newer styling.
Size
79.1 MB
Stars
16.3K
Age
11y
Commits · 90 Days