2 posts, 0 answers
  1. shovavnik
    shovavnik avatar
    39 posts
    Member since:
    Aug 2007

    Posted 06 May 2008 Link to this post

    I have to display a couple of charts in both left to right (LTR) and right to left (RTL) orientations, depending on the CurrentUICulture. It seems the chart doesn't support this.

    My current solution is to use code to move around the elements on the chart based on the culture. Here's the code I'm using:

    1 private void LocalizeChart(RadChart chart) 
    3     bool isRtl = RightToLeft == RightToLeft.Yes; 
    4     chart.Legend.Appearance.Position.AlignedPosition = isRtl ? AlignedPositions.Right : AlignedPositions.Left; 
    5     chart.PlotArea.YAxis.Visible = isRtl ? ChartAxisVisibility.True : ChartAxisVisibility.False; 
    6     chart.PlotArea.YAxis2.Visible = isRtl ? ChartAxisVisibility.False : ChartAxisVisibility.True; 
    7     chart.PlotArea.XAxis.Appearance.LabelAppearance.RotationAngle = CHART_X_AXIS_TEXT_ANGLE * (isRtl ? 1 : -1); 
    8 }

    This solves some of the display issues, but I couldn't find any easy way to cause the charts to appear in the "top left" quadrant so the values on the x-axis "increase" from right to left. The alignments should automatically "reverse" direction in RTL mode.

    Actually, I think there should be a property to specify whether a chart should stick to mathematical quadrants for the plot area, or to standard control alignment and direction. Not all charts show pure mathematical data.

    Is there any way currently to get the chart to reverse the x-axis direction?

    Thanks for any assistance!
  2. Dwight
    Dwight avatar
    475 posts

    Posted 07 May 2008 Link to this post

    Hi Noam,

    Unfortunately, the RadChart does not support Right-To-Left, and there are no plans for future extensions in this area for this version of the control.

    We have started working on the next version of the product and we will do our best to include RTL support in it.

    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. DevCraft R3 2016 release webinar banner
Back to Top