This is a migrated thread and some comments may be shown as answers.

Pie Chart transparent pie colors

6 Answers 122 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Michal
Top achievements
Rank 1
Michal asked on 10 Jan 2011, 06:20 PM
Hi!

I've been trying to set individual colors for the pie segments, this works ok. But the colors on the pie are somewhat less vivid that colors in legend - when I set a segment color to red, the legend is red, but the pie is pink. I've tried editing template for the pie:

<Ellipse Clip="{TemplateBinding FigurePath}" Height="{TemplateBinding ItemActualHeight}" Style="{TemplateBinding ItemStyle}" StrokeThickness="0" Width="{TemplateBinding ItemActualWidth}"  />

<
Path x:Name="PART_DefiningGeometry" Data="{TemplateBinding FigurePath2}" Fill="Transparent" Style="{TemplateBinding ItemStyle}" StrokeThickness="0" />

<
Ellipse Clip="{TemplateBinding FigurePath3}" Fill="{StaticResource PieMaskBrush}" Height="{TemplateBinding ItemActualHeight}" Width="{TemplateBinding ItemActualWidth}" StrokeThickness="0" />

               
The first ellipse seems to be responsible for the pie color: when I set the ellipse's color explicitly to red, the pie was red (not pink), but when the color comes from Style="{TemplateBinding ItemStyle}", it's pink. How do I achieve vivid color on pie?


Michal

6 Answers, 1 is accepted

Sort by
0
Sia
Telerik team
answered on 12 Jan 2011, 05:33 PM
Hi Michal,

Can you please try to set:
<telerik:RadChart x:Name="RadChart1" PaletteBrushesUseSolidColors="True" />

If you still experience the described problem, please let us know which theme you use.

Greetings,
Sia
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Michal
Top achievements
Rank 1
answered on 12 Jan 2011, 05:52 PM
Hi,
Worked great, thanks
Michal
0
Jean-Louis Lalonde
Top achievements
Rank 1
answered on 13 Jan 2011, 03:36 PM
Hi there,

I am also having trouble setting some custom colors. The color in question is #A3C5E1. For some reason the 3D pie chart is setting this color as transparent... Event when setting PaletteBrushesUseSolidColors="True".

Thanks.
0
Michal
Top achievements
Rank 1
answered on 13 Jan 2011, 03:59 PM
Hi, I'm just using 2D chart. I've tried the colour (adding FF in front of it) and it worked fine, displaying a light blue pie.
Michal
0
Jean-Louis Lalonde
Top achievements
Rank 1
answered on 13 Jan 2011, 04:20 PM
Hi,

I also tried adding #FF, but it did not change anything for me in the 3D mode...

JL
0
Sia
Telerik team
answered on 17 Jan 2011, 02:19 PM
Hi Jean-Louis Lalonde,

Actually the color which you have set is there but you cannot see it because the direction of the directional light makes it look transparent. A possible solution is to re-template the ChartArea and change the default direction. Please refer to the attached project and let us know if you need additional help.

Regards,
Sia
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
Tags
Chart
Asked by
Michal
Top achievements
Rank 1
Answers by
Sia
Telerik team
Michal
Top achievements
Rank 1
Jean-Louis Lalonde
Top achievements
Rank 1
Michal
Top achievements
Rank 1
Share this question
or