Today we would like to highlight one exciting feature that will find its way into the new RadChart control for WPF -- the control grants you the absolute freedom to compose its layout based on your business requirements and not the other way around. This effectively means that you can add an unlimited number of chart building blocks (chart areas, legends, and titles) so we will demonstrate now how easy the layout customization can be.
Basically the control provides three options for layout customization:
Let us give this a try and try to replicate this sample layout:
Option 1: Customizing the Default Template
First we need to declare a resource for our custom template that should hold two ChartArea instances, a title and a legend. We will use the standard Grid panel to accommodate the elements. We also need to associate the chart areas with the respective legend they will use and apply the template like this:
Let's feed our control some sample data:
Here is the final result:
Note that with this approach you have a direct reference to the ChartArea instance (instead of using FindName(...) lookup) like this:
And the resultant layout is the same:
Hope this helps.
Copyright © 2017, Progress Software Corporation and/or its subsidiaries or affiliates. All Rights Reserved.
Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks or appropriate markings.