Show / Hide Table of Contents

Class Themes

A helper class that can automatically theme any XAML control or window using the VS theme properties.

Inheritance
System.Object
Themes
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Community.VisualStudio.Toolkit
Assembly: Community.VisualStudio.Toolkit.dll
Syntax
public static class Themes
Remarks

Should only be referenced from within .xaml files.

Examples
<UserControl x:Class="MyClass"
xmlns:toolkit="clr-namespace:Community.VisualStudio.Toolkit;assembly=Community.VisualStudio.Toolkit"
toolkit:Themes.UseVsTheme="True">
</UserControl>

Fields

| Improve this Doc View Source

UseVsThemeProperty

The property to add to your XAML control.

Declaration
public static readonly DependencyProperty UseVsThemeProperty
Field Value
Type Description
System.Windows.DependencyProperty

Methods

| Improve this Doc View Source

GetUseVsTheme(UIElement)

Gets the UseVsTheme property from the specified element.

Declaration
public static bool GetUseVsTheme(UIElement element)
Parameters
Type Name Description
System.Windows.UIElement element
Returns
Type Description
System.Boolean
| Improve this Doc View Source

SetUseVsTheme(UIElement, Boolean)

Sets the UseVsTheme property.

Declaration
public static void SetUseVsTheme(UIElement element, bool value)
Parameters
Type Name Description
System.Windows.UIElement element
System.Boolean value
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX