Smith: Adding markers causes series to move

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Christo Zietsman
Newbie
Newbie
Posts: 34
Joined: Thu Sep 04, 2008 12:00 am

Smith: Adding markers causes series to move

Post by Christo Zietsman » Thu Oct 09, 2008 9:58 am

I've uploaded two images:
1. p1.PNG Length 51588
2. p2.PNG Length 49753

These two images shows what happens when I:
1. have the two lines to show marks commented out
2. include the tow lines to show marks.

I have two issues:

The first and most important issue is that the second series does not render correctly on the chart when the marks are shown.

The second issue is that when we show the marks the smith chart area is smaller than when we don't. Look at the space difference between the header text and the top of the chart area.

The xaml:

Code: Select all

<Window x:Class="WPFDemo.SmithWindow3"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:WPF="clr-namespace:Steema.TeeChart.WPF;assembly=TeeChart.WPF"
    Title="Window2" Width="800" Height="600">
    <Grid>
        <WPF:TChart Margin="0,0,0,0" Name="Chart" />
    </Grid>
</Window>

The code behind:

Code: Select all

using System;
using System.Windows;
using System.Windows.Media;
using Steema.TeeChart.WPF.Styles;

namespace WPFDemo
{
    /// <summary>
    /// Interaction logic for SmithWindow3.xaml
    /// </summary>
    public partial class SmithWindow3 : Window
    {
        public SmithWindow3()
        {
            InitializeComponent();
            InitializeChart();
        }        

        private void InitializeChart()
        {
            Chart.Aspect.View3D = false;

            Smith smith = new Smith();
            smith.Pointer.Brush.Visible = false;
            smith.Pointer.Pen.Visible = false;
            smith.Circled = true;
            smith.Add(0.79179995592949659, 0.14388594764063792);
            smith.Add(0.8647277042181758, -0.0081370575495096509);
            smith.Add(0.8524625931032126, -0.17622440105160339);
            smith.Add(0.767156825803257, -0.30612640281506492);
            smith.Add(0.6506441001998764, -0.37464735034203056);

            // uncomment these two lines to turn the marks off
            smith.Marks.Visible = true;
            smith.Marks.DrawEvery = 2;   
            Chart.Series.Add(smith);

            Smith smith2 = new Smith();
            smith2.Circled = true;
            smith2.Pointer.Color = Colors.Black;
            smith2.Pointer.Style = PointerStyles.Cross;
            smith2.Add(0.8524625931032126, -0.17622440105160339);
            Chart.Series.Add(smith2);

            double[] realValues = 
            {
                0.5,
                1,
                2,
                1,
                0.5
            };

            double[] imagValues = 
            {
                0,
                -0.75,
                0,
                0.75,
                0
            };

            Smith smith3 = new Smith();
            smith3.Circled = true;
            smith3.ImagSymbol = "i";
            smith3.Pointer.Style = PointerStyles.Nothing;
            smith3.Add(realValues, imagValues);
            Chart.Series.Add(smith3);
        }
    }
}

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Oct 09, 2008 11:18 am

Hi Christo,

Thanks for the information. I could reproduce the issue here and added it (TF02013442) to the defect list to be fixed for next releases.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Christo Zietsman
Newbie
Newbie
Posts: 34
Joined: Thu Sep 04, 2008 12:00 am

Post by Christo Zietsman » Fri Oct 10, 2008 8:12 am

Thanks Narcís,

I think the same issue is also applicable to polar series.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Oct 10, 2008 9:07 am

Hi Christo,

Thanks for the information. Most likely this is a problem in base series class (Steema.TeeChart.Styles.Circular).
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply