Features > Style and Appearance > Apply Themes |
GanttView supports built-in ComponentOne themes available in C1.WPF.Theming library. You can apply any of the available C1 themes to the GanttView control and provide a customized and consistent appearance to the application. To understand how themes can be used effectively, see Theming.
The following image shows a GanttView with C1WhistlerBlue theme applied to it.
The following steps illustrate how to apply C1 themes to GanttView. This example uses the sample created in the Quick start.
Imports C1.WPF.Theming Imports C1.WPF.Theming.WhistlerBlue
using C1.WPF.Theming; using C1.WPF.Theming.WhistlerBlue;
Public Class MyThemes Private Shared _myTheme As C1Theme = Nothing Public Shared ReadOnly Property MyTheme() As C1Theme Get If _myTheme Is Nothing Then _myTheme = New C1ThemeWhistlerBlue() End If Return _myTheme End Get End Property End Class
public class MyThemes { private static C1Theme _myTheme = null; public static C1Theme MyTheme { get { if (_myTheme == null) { _myTheme = new C1ThemeWhistlerBlue(); } return _myTheme; } } }
'Apply C1 theme to GanttView
C1Theme.ApplyTheme(gv, MyThemes.MyTheme)
//Apply C1 theme to GanttView
C1Theme.ApplyTheme(gv, MyThemes.MyTheme);