Page 1 of 1

Mouse Cursor on chart does not change to Arrow 3.5.3274.3066

Posted: Tue May 26, 2009 5:11 pm
by 13048149
Hi There,

When DragMarks are set to a Line series the mouse cursor does not change back to Arrow after moving the mouse away from any tool (Vertical Chart Cursor, Hand Cursor on the Drag Marks)

Best Regards
Srinivas Avancha.

Code: Select all

        private void Form1_Load(object sender, EventArgs e)
        {
            Steema.TeeChart.TChart tChart1 = new Steema.TeeChart.TChart();
            Steema.TeeChart.Styles.FastLine fastLine1 = new Steema.TeeChart.Styles.FastLine();
            Steema.TeeChart.Tools.CursorTool cursorTool1 = new Steema.TeeChart.Tools.CursorTool();
            Steema.TeeChart.Styles.Line line1 = new Steema.TeeChart.Styles.Line();

            this.Controls.Add(tChart1);

            tChart1.Dock = DockStyle.Fill;
            tChart1.Aspect.View3D = false;

            cursorTool1.Style = Steema.TeeChart.Tools.CursorToolStyles.Vertical;
            tChart1.Tools.Add(cursorTool1);


            fastLine1.FillSampleValues(20);
            line1.FillSampleValues(2);

            tChart1.Series.Add(fastLine1);
            tChart1.Series.Add(line1);

            line1.LinePen.Width = 3;

            Steema.TeeChart.Tools.DragMarks tempDragMarks = new Steema.TeeChart.Tools.DragMarks(tChart1.Chart);
            tempDragMarks.Series = line1;
            line1.Marks.Visible = true;
        }

Posted: Wed May 27, 2009 12:54 pm
by narcis
Hi Srinivas,

This works fine for me here using mentioned build. Can you please check your project's TeeChart.dll was updated correctly?

Thanks in advance.

Posted: Wed May 27, 2009 3:02 pm
by 13048149
Hi NarcĂ­s,

Uploaded zip file containing the source code and the bin with the TeeChart.dll.
Removed the fastline that was not necessary and changed the code as below. (simplified)

Thanks.

Code: Select all

        private void Form1_Load(object sender, EventArgs e)
        {
            Steema.TeeChart.TChart tChart1 = new Steema.TeeChart.TChart();
            Steema.TeeChart.Tools.CursorTool cursorTool1 = new Steema.TeeChart.Tools.CursorTool(tChart1.Chart);
            Steema.TeeChart.Styles.Line line1 = new Steema.TeeChart.Styles.Line(tChart1.Chart);

            this.Controls.Add(tChart1);

            tChart1.Dock = DockStyle.Fill;
            tChart1.Aspect.View3D = false;

            cursorTool1.Style = Steema.TeeChart.Tools.CursorToolStyles.Vertical;


            line1.FillSampleValues(2);
            line1.LinePen.Width = 3;

            //Adding DragMarks tool causes cursor not to change back to Arrow.
            Steema.TeeChart.Tools.DragMarks tempDragMarks = new Steema.TeeChart.Tools.DragMarks(tChart1.Chart);
            tempDragMarks.Series = line1;
            line1.Marks.Visible = true;
        }

Posted: Wed May 27, 2009 3:19 pm
by yeray
Hi Srinivas,

I've seen the problem with your project, I've changed the reference to the latest TeeChart v3 NET release available and now it seems to work fine.

Posted: Wed May 27, 2009 3:59 pm
by 13048149
Hi Yeray,

Ver 3.5.3425.20245 did fix the above problem, but introduced another problem clicking on the line changes the width.

Thanks
Srinivas

Code: Select all

        private void Form1_Load(object sender, EventArgs e)
        {
            Steema.TeeChart.TChart tChart1 = new Steema.TeeChart.TChart();
            Steema.TeeChart.Tools.CursorTool cursorTool1 = new Steema.TeeChart.Tools.CursorTool(tChart1.Chart);
            Steema.TeeChart.Styles.Line line1 = new Steema.TeeChart.Styles.Line(tChart1.Chart);

            this.Controls.Add(tChart1);

            tChart1.Dock = DockStyle.Fill;
            tChart1.Aspect.View3D = false;

            cursorTool1.Style = Steema.TeeChart.Tools.CursorToolStyles.Vertical;
            //cursorTool1.FollowMouse = true;


            line1.FillSampleValues(2);
            line1.LinePen.Width = 3;
            line1.Click += new MouseEventHandler(line1_Click);

            //Adding DragMarks tool causes cursor not to change back to Arrow.
            Steema.TeeChart.Tools.DragMarks tempDragMarks = new Steema.TeeChart.Tools.DragMarks(tChart1.Chart);
            tempDragMarks.Series = line1;
            line1.Marks.Visible = true;
        }

        void line1_Click(object sender, MouseEventArgs e)
        {
            Steema.TeeChart.Styles.Line line1 = sender as Steema.TeeChart.Styles.Line;
            line1.OutLine.Style = DashStyle.Dot;
            line1.OutLine.Visible = !line1.OutLine.Visible;
        }

Posted: Thu May 28, 2009 9:06 am
by yeray
Hi Srinivas,

I've tested your project in two different machines and I've seen:
- I could reproduce cursor issue but not linepen issue with version 3.5.3274.30664.
- I couldn't reproduce cursor issue but could reproduce linepen issue with version 3.5.3425.20245 (and actual v3 sources).
- I couldn't reproduce either cursor issue nor linepen issue with actual v4 sources.

So please, could you verify again that you have the correct reference to 3.5.3425.20245 in your project? This should solve your cursor problem.

I think that the linepen problem is related to the LinePen issue (TF02014158) so I've incremented its priority.

Posted: Thu May 28, 2009 12:30 pm
by 13048149
Hi Yeray,

Uploaded TrendLineCursor (2).zip file containing the source code and the bin with the TeeChart.dll.

Click on the thick line, you will see the line with outline and the line is thin.
Click again to remove outline and the line is still thin.

Thanks
Srinivas.

Posted: Thu May 28, 2009 2:32 pm
by yeray
Hi Srinivas,

Yes, as I said above, I could reproduce this "linepen issue" with v3 but not with v4.
As a workaround you could set outlinepen width to 3 at Form1_Load method.

Posted: Thu May 28, 2009 2:40 pm
by 13048149
Hi Yeray,

Ver 3.5.3425.20245 did fix the cursor problem, unfortunately can not upgrade to this version because of the Linepen issue (too much of workaround as the feature of outline/un outline is used at lot in our code). Thanks for looking into the problem and we will be waiting for the TF02014158 fix.

Appreciate your quick response.

Thanks
Srinivas.