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
1300
shift y axis
posted

Hi ,

I have a plot like this :

 

I would like to shift the why axis to the label , I use the followinf fillscene graph :

 private void Chartquadrant_FillSceneGraph(object sender, Infragistics.UltraChart.Shared.Events.FillSceneGraphEventArgs e)
        {
            foreach (Primitive item in e.SceneGraph)
            {


                if (item.GetType() == typeof(Line) && ((Line)item).lineStyle.DrawStyle != LineDrawStyle.Dash)
                {
                    if (((Line)item).p1.X == ((Line)item).p2.X)
                    {
                        ((Line)item).p1.Offset(this.Chartquadrant.Width / 2, 0);
                        ((Line)item).p2.Offset(this.Chartquadrant.Width / 2, 0);
                    }
                    else
                    {
                        ((Line)item).p1.Offset(0, -400);
                        ((Line)item).p2.Offset(0, -400);
                    }
                }

                Text pl = item as Text;
                if (pl != null && ((Text)item).labelStyle.Orientation == TextOrientation.VerticalLeftFacing)
                {
                    ((Text)item).bounds = new Rectangle(((Text)item).bounds.X + 0, ((Text)item).bounds.Y - (400), ((Text)item).bounds.Width, ((Text)item).bounds.Height);
                }

                if (pl != null && ((Text)item).labelStyle.Orientation == TextOrientation.Horizontal)
                {
                    ((Text)item).bounds = new Rectangle(((Text)item).bounds.X + this.Chartquadrant.Width / 2 - 50, ((Text)item).bounds.Y, ((Text)item).bounds.Width, ((Text)item).bounds.Height);
                }


            }
        }

 

Do you have any idea of how i can do that ?

 

Thanks.

 

F.