Version

Chart Title and Subtitle

Topic Overview

Purpose

The title and subtitle feature of the XamCategoryChart control allows you to add information to the top section of the chart control.

When adding a title or subtitle to the chart control, the content of the chart automatically resizes allowing for the title and subtitle information.

Required Background

The following topics are prerequisites to understanding this topic:

Topic Purpose

This topic provides conceptual information about the XamCategoryChart control including its main features, minimum requirements, and user functionality.

This topic explains how to bind data to the XamCategoryChart control.

In this topic

This topic contains the following sections:

Property Settings

You can customize the look and feel of the category chart’s subtitle and title in many different ways such as applying different font styles, margins, and alignment. This can be achieved through the following properties:

Property Name Property Type Description

string

Title’s text content.

HorizontalAlignment

Title’s horizontal alignment.

double

Title’s bottom margin.

FontAttributes

Title’s font style.

string

Title’s font name.

double

Title’s font size

double

Title’s left margin.

double

Title’s right margin.

Title’s text color.

double

Title’s top margin.

string

Subtitle’s text content.

HorizontalAlignment

Subtitle’s horizontal alignment.

double

Subtitle’s bottom margin.

FontAttributes

Subtitle’s font style.

string

Subtitle’s font name.

double

Subtitle’s text size.

double

Subtitle’s left margin.

double

Subtitle’s right margin.

Subtitle’s text color.

double

Subtitle’s top margin.

Code Snippet

The following code example shows how to customize the title and subtitle: In XAML:

<ig:XamCategoryChart x:Name="CategoryChart"
                     Title="Energy Use Per Country"
                     TitleTextColor="Red"
                     TitleFontFamily="Verdana"
                     TitleFontSize="24"
                     Subtitle="Results over a two year periods"
                     SubtitleTextColor="Red"
                     SubtitleFontFamily="Verdana"
                     SubtitleFontSize="16">
</ig:XamCategoryChart>

In C#:

In Visual Basic:

categorychart chart title subtitle 01.png

Related Content

Topic Purpose

This article will get you up and running with the Category Chart control.