- Welcome, Guest. Please Login or Register
MindFusion  
  We are soon releasing MindFusion.JavaScript pack. Initial version includes chart, diagram, calendar, map, virtual keyboard, gauge and UI components. Here are the beta version and live demo for anyone interested.  
  HomeHelpSearchLoginRegister   
     
     
   
 
Page Index Toggle Pages: 1 Send Topic Print  
the internal label position(Reporting.pieChart)
Read 5279 times

cfn_zzq   Offline
YaBB Newbies
*
Posts: 4
I Love MindFusion!


   
     
 
the internal label position(Reporting.pieChart)
Jun 7th, 2013 at 9:00am
 
How to set the internal label into the pie chart, and how to set the percentage with decimal point?
 
 

__25429___33719__002.PNG (Attachment deleted)
 
IP Logged    
 
     

Meppy   Offline
YaBB Moderator
*****
Posts: 1783
Gender: male
MindFusion support


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #1 - Jun 7th, 2013 at 11:33am
 
Have a look at this version:

http://mindfusion.eu/_temp/MindFusion.Reporting.Wpf.trial.zip

The PieChart class exposes two new properties that enable you to control the position of the chart labels, namely InnerLabelLocation and OuterLabelOffset.

InnerLabelLocation is a value in the interval [0..1] which specifies the relative location of the inner labels along the radius length. The default is 0.85, which positions the inner labels just outside the chart. You can try with smaller values, for example 0.5. OuterLabelOffset is an absolute value specifying the offset of the outer labels.

Specifying formatting for the displayed label values is currently not possible, but something we will consider adding in the next version of the control.

Regards,
Meppy
 
 
 
IP Logged    
 
     

luolishuang   Offline
YaBB Newbies
*
Posts: 40
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #2 - Jun 8th, 2013 at 2:37am
 
Meppy wrote on Jun 7th, 2013 at 11:33am:
Have a look at this version:

http://mindfusion.eu/_temp/MindFusion.Reporting.Wpf.trial.zip

The PieChart class exposes two new properties that enable you to control the position of the chart labels, namely InnerLabelLocation and OuterLabelOffset.

InnerLabelLocation is a value in the interval [0..1] which specifies the relative location of the inner labels along the radius length. The default is 0.85, which positions the inner labels just outside the chart. You can try with smaller values, for example 0.5. OuterLabelOffset is an absolute value specifying the offset of the outer labels.

Specifying formatting for the displayed label values is currently not possible, but something we will consider adding in the next version of the control.

Regards,
Meppy


Hi Meppy,

This is a colleague of mine, Can take me a newest official version of dlls?

Best Regards,
Luo Lishuang
 
 
 
IP Logged    
 
     

luolishuang   Offline
YaBB Newbies
*
Posts: 40
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #3 - Jun 9th, 2013 at 2:10am
 
Hi Meppy,

The PieChart in report could NOT be exported to Excel file?
any solution?


Best Regards,
Luo Lishuang
 
 
 
IP Logged    
 
     

luolishuang   Offline
YaBB Newbies
*
Posts: 40
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #4 - Jun 9th, 2013 at 2:51am
 
also,The PieChart exported to PDF file has a little problem, like image below, why the image in PDF file can NOT be consistent at source image?
 
 

source.PNG (Attachment deleted)
in_PDF.PNG (Attachment deleted)
 
IP Logged    
 
     

Meppy   Offline
YaBB Moderator
*****
Posts: 1783
Gender: male
MindFusion support


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #5 - Jun 9th, 2013 at 8:59am
 
Hi,

We were able to reproduce the bug with the PDF export and will look into it. Regarding exporting charts to excel, this is currently not supported, but we have plans to extend our excel exporter in the near (even though not immediate) future so you may stay tuned.

Regards,
Meppy
 
 
 
IP Logged    
 
     

cfn_zzq   Offline
YaBB Newbies
*
Posts: 4
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #6 - Jun 17th, 2013 at 3:56am
 
In the pieChart,the A,B,C block color is red,the D block is blue, and the Other block is gray.How can i achieve it?
 
 
 
IP Logged    
 
     

Meppy   Offline
YaBB Moderator
*****
Posts: 1783
Gender: male
MindFusion support


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #7 - Jun 17th, 2013 at 6:39am
 
You can assign brushes for the individual pie pieces through the PieChart.Brushes property. For example, you can do that in XAML like this:

Code:
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:r="http://mindfusion.eu/reporting/wpf">
...
<x:ArrayExtension Type="{x:Type Brush}" x:Key="PieBrushes">
	<SolidColorBrush Color="#FF0000" />
	<SolidColorBrush Color="#FF0000" />
	<SolidColorBrush Color="#FF0000" />
	<SolidColorBrush Color="#0000FF" />
	<SolidColorBrush Color="#C0C0C0" />
	<SolidColorBrush Color="#C0C0C0" />
	<SolidColorBrush Color="#C0C0C0" />
	<SolidColorBrush Color="#C0C0C0" />
</x:ArrayExtension>
...
<r:PieChart Brushes="{StaticResource PieBrushes}"  /> 


Regards,
Meppy
 
 
 
IP Logged    
 
     

cfn_zzq   Offline
YaBB Newbies
*
Posts: 4
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #8 - Jun 17th, 2013 at 9:52am
 
The property of PieChart Brushes is set by code.  I don't know why it does not display?

myReport.QueryDetails += (s, e) =>
{
   MindFusion.Reporting.Wpf.PieChart pieChart = s as MindFusion.Reporting.Wpf.PieChart;
   if (item != null)
   {
      List<Brush> lst = new List<Brush>
      {
         new SolidColorBrush(Color.FromRgb(Convert.ToByte(110),Convert.ToByte(110),Convert.To
Byte(110))),
         ...
      };
      pieChart.Brushes = lst;
      e.Details = ...                            
    }
}
 
 
 
IP Logged    
 
     

Meppy   Offline
YaBB Moderator
*****
Posts: 1783
Gender: male
MindFusion support


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #9 - Jun 17th, 2013 at 10:40am
 
More appropriate place to customize appearance would be the Prerender event. There you can directly customize the appearance properties of the rendered PieChart:

Code:
var pieChart = e.RootVisual as MindFusion.Charting.Wpf.PieChart;
if (pieChart != null)
{
	pieChart.Series[0].Fills.Clear();
	pieChart.Series[0].Fills.Add(new SolidColorBrush(Color.FromRgb(110, 110, 110)));
} 


Note that RootVisual is an instance of MindFusion.Charting.Wpf.PieChart and not the original MindFusion.Reporting.Wpf.PieChart report item.

Regards,
Meppy
 
 
 
IP Logged    
 
     

cfn_zzq   Offline
YaBB Newbies
*
Posts: 4
I Love MindFusion!


   
     
 
Re: the internal label position(Reporting.pieChart)
Reply #10 - Jun 18th, 2013 at 3:49am
 
Thanks for your help.
 
 
 
IP Logged    
 
     
Page Index Toggle Pages: 1 Send Topic Print