[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
 [Expand]What's Installed
 [Expand].NET Core 3 Support
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Collapse]Charts Suite
   [Collapse]Chart Control
    [Expand]Getting Started
    [Expand]Providing Data
    [Expand]Chart Elements
    [Collapse]Appearance Customization
      Chart Themes and Palettes
      Custom Draw
      Series and Series Point Colors
      Series and Marker Models
      Segment Colorizers
    [Expand]End-User Features
    [Expand]Design-Time Features
    [Expand]Additional Resources
   [Expand]Chart3D Control
  [Expand]Pivot Grid
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Gantt Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Chart Themes and Palettes

This document explains how to apply a theme to your chart, use built-in palettes to change the appearance of a particular chart element and create your custom palette.

DXCharts provides the capability to not only customize the appearance (font, style, color, etc.) of any chart element (Diagram, axis, point, label, etc.) but also assign a theme to the entire chart. In addition, several built-in palettes can be used to automatically color bars in a bar series view, sectors in a pie view, etc., in minimal time and with minimal effort.

This document includes the following sections.

Expanded Assign a Theme to a Chart

A theme specifies the appearance of all of the chart's visual elements, and thus defines the overall look and feel.

The following images show a Stacked Area chart with two different themes applied: DXStyle and LightGray.

ThemeName = DXStyle ThemeName = LightGray

To assign a theme to your chart, add the corresponding assemblies to the Reference list of your project.

For a full list of available theme assemblies, see the List of DevExpress WPF Themes document.

Next, add the following reference to your application's Window.

Set the ThemeManager.ThemeName property to the required theme name.

The ThemeName property affects the look and feel of the entire application. In case this property is defined multiple times (e.g., with different themes assigned to various controls), only the most recent assignment is taken into account.

For an example of theme use, see How to: Use Themes to Define the Look and Feel of Your Chart.

Expanded Built-in Palettes

The ChartControlBase.Palette property defines colors in which to paint Series or Series Points. When the XYSeries.ColorEach property is enabled, the color of each point is specified from the current palette.

The Palette property can be set either to one of the standard palettes, or to a CustomPalette object.

The two built-in palettes applied to a chart with Bar (the ColorEach property is enabled) and Line series are shown below.

Palette = DXChartsPalette Palette = PastelKitPalette

The name of the currently selected palette can be accessed via its PaletteName property (e.g., DXChartsPalette.PaletteName, PastelKitPalette.PaletteName, etc.). If some of the default palette colors were manually changed, you can obtain the currently used set of colors via the ChartControlBase.Palette property.

The following example shows how to use palettes: How to: Use the Chart Palette for Painting Series and their Points

Expanded Custom Palette

To create a custom palette, do the following:

The second step can be implemented using the Color Collection Editor.

To invoke this editor, click the Colors ellipsis button in the Properties window, as shown in the image below.

In the image below, you can see the Color Collection Editor with Blue, Yellow and Magenta colors added to the color collection.

Chart series color from this custom palette are shown below:

For more information on chart appearance customization, see the Series and Marker Models and Custom Draw topics.

Expanded Example

Is this topic helpful?​​​​​​​