windowsforms-devexpress-dot-skins-dot-skinmanager-e17f2425.md
Provides access to the default skin manager.
Namespace : DevExpress.Skins
Assembly : DevExpress.Utils.v25.2.dll
NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core
public static SkinManager Default { get; }
Public Shared ReadOnly Property [Default] As SkinManager
| Type | Description |
|---|---|
| SkinManager |
A SkinManager object that represents the default skin manager.
|
The following code shows how to populate a combo box editor with names of available skins. When a specific item is selected from the editor’s dropdown, the corresponding skin is applied to controls.
To get the available skin names, the SkinManager.Skins property is used.
In this example, the selected skin is applied via the DefaultLookAndFeel object. It specifies look and feel settings used by all Developer Express controls and forms by default.
using DevExpress.XtraEditors;
using DevExpress.Skins;
// Handle the SelectedIndexChanged event to respond to selecting the skin name.
comboBoxEdit1.SelectedIndexChanged += new EventHandler(comboBoxEdit1_SelectedIndexChanged);
// Add available skin names to the combo box.
foreach(SkinContainer cnt in SkinManager.Default.Skins) {
comboBoxEdit1.Properties.Items.Add(cnt.SkinName);
}
//...
void comboBoxEdit1_SelectedIndexChanged(object sender, EventArgs e) {
ComboBoxEdit comboBox = sender as ComboBoxEdit;
string skinName = comboBox.Text;
DevExpress.LookAndFeel.UserLookAndFeel.Default.SkinName = skinName;
}
Imports DevExpress.XtraEditors
Imports DevExpress.Skins
' Handle the SelectedIndexChanged event to respond to selecting the skin name.
AddHandler ComboBoxEdit1.SelectedIndexChanged, AddressOf comboBoxEdit1_SelectedIndexChanged
' Add available skin names to the combo box.
For Each cnt As SkinContainer In SkinManager.Default.Skins
ComboBoxEdit1.Properties.Items.Add(cnt.SkinName)
Next cnt
'...
Sub comboBoxEdit1_SelectedIndexChanged(ByVal sender As System.Object, _
ByVal e As System.EventArgs)
Dim comboBox As ComboBoxEdit = sender
Dim skinName As String = comboBox.Text
DevExpress.LookAndFeel.UserLookAndFeel.Default.SkinName = skinName
End Sub
See Also