Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1175
XamDoughnutChart Syles
posted

I am currently trying to use the HierarchicalRingSeries in the XamDoughnutChart.  Currently both the label and slice borders render so bad I cannot use this control for commercial release.

With certain colors the white border completely disappears and with certain colors the label disappears into the background.  Is there a way to

1) change the slice border width and/or color.

2) be able to bind a converter so the label color can be rendered based upon the background color.

Here is a screenshot of the chart

On some monitors there are no white slice dividers, on others only the green area shows no dividers.  Also, I need to be able to have the ability to display white labels on dark colors such as the blue or black while rendering black labels on the lighter colors.  Our customers have the ability to set the color of data types to any color.

  • 34430
    Verified Answer
    Offline posted

    Hello Richard,

    I have been investigating into your requirements in this case, and it is odd that you are seeing the behavior you are seeing with the divider lines on some machines but not others. This appears to be causing the background of the chart to be bleeding through the slight border. Please note that the HierarchicalRingSeries object is still in a preview (CTP) state as well. With that said, I have been looking into the behaviors you are looking to achieve, and I have some information for you. I will answer your questions in the order they were asked.

    1. In order to change the slice’s border color, you can set the Outlines property on the HierarchicalRingSeries. This works much like the Brushes collection in that if you define multiple colors, it will be applied based on slice index. If you define a single color, that color will be applied to all outlines. There does not currently exist a way to change the border width that I can see.

    2. You can bind a converter for the label color if you use a LabelTemplate for your HierarchicalRingSeries. I am attaching a sample project to demonstrate this.

    If you would like to see the ability to change the outline thickness of the slices, I would recommend suggesting a new product idea for this at our WPF Ideas Site, here. This will place you in direct communication with our product management teams who plan and prioritize upcoming features and development based on community and user feedback.

    Please let me know if you have any other questions or concerns on this matter.

    XamDoughnutChartHierarchicalDemo.zip