Sets a theme settings for the whole application.

Namespace: Elysium
Assembly: Elysium (in Elysium.dll) Version: 2.0.976.4 (2.0.976.4)

Syntax

C#
public static void Apply(
	this Application application,
	Nullable<Theme> theme,
	SolidColorBrush accentBrush,
	SolidColorBrush contrastBrush
)
Visual Basic
<ExtensionAttribute> 
Public Shared Sub Apply ( 
	application As Application,
	theme As Nullable(Of Theme),
	accentBrush As SolidColorBrush,
	contrastBrush As SolidColorBrush
)

Parameters

application
Type: System.Windows..::..Application
An instance of the application, whose settings are being set.
theme
Type: System..::..Nullable<(Of <(<'Theme>)>)>
One of the values of the enumeration Theme, or null.
accentBrush
Type: System.Windows.Media..::..SolidColorBrush
A brush, which contains an accent colour, or null.
contrastBrush
Type: System.Windows.Media..::..SolidColorBrush
A brush, which contains a contrast colour, or null.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Application. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

Remarks

If the parameter is null:
  1. If the parameter was set, old value will be used.
  2. If the parameter was not set, default value will be used.

Exceptions

ExceptionCondition
System..::..ArgumentNullException Parameter application is null.

Contracts

See Also