Approved
Last Updated: 30 Apr 2018 11:33 by ADMIN
ADMIN
Dess | Tech Support Engineer, Sr.
Created on: 17 Apr 2018 09:25
Category: ChartView
Type: Bug Report
1
FIX. RadChartView - axis label is clipped or completely disappears when you change its font and it is multi-lined
To reproduce:
        public RadForm1()
        {
            InitializeComponent(); 

            this.radChartView1.AreaType = ChartAreaType.Polar;
            PolarAreaSeries polarAreaSeries = new PolarAreaSeries();
            PolarDataPoint polarPoint = new PolarDataPoint();
            polarPoint.Value = 35;
            polarPoint.Angle = 50;
            polarAreaSeries.DataPoints.Add(polarPoint);
            polarPoint = new PolarDataPoint();
            polarPoint.Value = 40;
            polarPoint.Angle = 200;
            polarAreaSeries.DataPoints.Add(polarPoint);
            polarPoint = new PolarDataPoint();
            polarPoint.Value = 55;
            polarPoint.Angle = 320;
            polarAreaSeries.DataPoints.Add(polarPoint);

            this.radChartView1.Series.Add(polarAreaSeries);
            
            this.radChartView1.Axes[0].LabelFitMode = AxisLabelFitMode.Rotate;
            AxisLabelElement gauche = this.radChartView1.Axes[0].Children[1] as AxisLabelElement;
            gauche.Text = "IV Gestion des ressources" + Environment.NewLine + "humaines";
            
          
              this.radChartView1.View.AxisLabelFormatting+=View_AxisLabelFormatting;
        }

        Font f = new Font("Arial", 10, FontStyle.Bold);

        private void View_AxisLabelFormatting(object sender, ChartAxisLabelFormattingEventArgs e)
        {
            if (e.LabelElement.Text.Contains("IV"))
            {
                e.LabelElement.Font = f;
            }
        }
0 comments