To customize the TreeMap label font style and label text alignment, refer to the following steps.
Add ItemsSource and levels in order to populate the TreeMap.
Note: Refer to the sample for PopulationDetails provided for ItemsSource.
You can customize TreeMap label font style and label text alignment by using LeafItemDrawing event.
Set e.cancel as true inside the event in order to redefine TreeMap label font style and text alignment.
The following screenshot illustrates the output.
Figure 1: Treemap label with customized font style and label text alignment
This page will automatically be redirected to the sign-in page in 10 seconds.