TeeChart locks up when using LogarithmicBase
Posted: Fri Aug 12, 2011 1:33 pm
Hi,
I'm using TeeChar version 4.1.2011.7283 (latest version so far) with WPF and VS2010SP1. If I use a logarithmic scale on one of the axis in conjunction with a given LogarithmicBase, then TeeChart will lock up (100% CPU time) if I resize (making it larger) or maximize the dialog.
Even worse, if I comment out the line "mQtLine.Add(160.39, 0);" the program will not start at all. If I do not use the line "TcQx.Axes.Bottom.LogarithmicBase = 0.01;" everything seems to be normal.
Here's the code for a small test program (complete project can be provided on demand):
MainWindow.xaml.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace TeeChartError
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window
{
Steema.TeeChart.WPF.Styles.FastLine mQtLine;
public MainWindow()
{
InitializeComponent();
TcQx.Aspect.View3D = false;
TcQx.Legend.Visible = false;
TcQx.Header.Lines = new string[] { "q(x)-Diagram" };
TcQx.Axes.Bottom.Title.Lines = new string[] { "Particle size [µm]" };
TcQx.Axes.Left.Title.Lines = new string[] { "Distribution density (q3)" };
TcQx.Axes.Bottom.Logarithmic = true;
TcQx.Axes.Bottom.LogarithmicBase = 0.01;
mQtLine = new Steema.TeeChart.WPF.Styles.FastLine();
mQtLine.Add(0.67, 0.02);
mQtLine.Add(0.99, 0.06);
mQtLine.Add(1.2, 0.11);
mQtLine.Add(1.4, 0.16);
mQtLine.Add(160.39, 0);
TcQx.Series.Add(mQtLine);
}
}
}
MainWindow.xaml:
<Window x:Class="TeeChartError.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006 ... esentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="350" Width="525" xmlns:my="clr-namespace:Steema.TeeChart.WPF;assembly=TeeChart.WPF">
<Grid>
<my:TChart Name="TcQx" />
</Grid>
</Window>
Thanks for any help on this problem.
I'm using TeeChar version 4.1.2011.7283 (latest version so far) with WPF and VS2010SP1. If I use a logarithmic scale on one of the axis in conjunction with a given LogarithmicBase, then TeeChart will lock up (100% CPU time) if I resize (making it larger) or maximize the dialog.
Even worse, if I comment out the line "mQtLine.Add(160.39, 0);" the program will not start at all. If I do not use the line "TcQx.Axes.Bottom.LogarithmicBase = 0.01;" everything seems to be normal.
Here's the code for a small test program (complete project can be provided on demand):
MainWindow.xaml.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace TeeChartError
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window
{
Steema.TeeChart.WPF.Styles.FastLine mQtLine;
public MainWindow()
{
InitializeComponent();
TcQx.Aspect.View3D = false;
TcQx.Legend.Visible = false;
TcQx.Header.Lines = new string[] { "q(x)-Diagram" };
TcQx.Axes.Bottom.Title.Lines = new string[] { "Particle size [µm]" };
TcQx.Axes.Left.Title.Lines = new string[] { "Distribution density (q3)" };
TcQx.Axes.Bottom.Logarithmic = true;
TcQx.Axes.Bottom.LogarithmicBase = 0.01;
mQtLine = new Steema.TeeChart.WPF.Styles.FastLine();
mQtLine.Add(0.67, 0.02);
mQtLine.Add(0.99, 0.06);
mQtLine.Add(1.2, 0.11);
mQtLine.Add(1.4, 0.16);
mQtLine.Add(160.39, 0);
TcQx.Series.Add(mQtLine);
}
}
}
MainWindow.xaml:
<Window x:Class="TeeChartError.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006 ... esentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="350" Width="525" xmlns:my="clr-namespace:Steema.TeeChart.WPF;assembly=TeeChart.WPF">
<Grid>
<my:TChart Name="TcQx" />
</Grid>
</Window>
Thanks for any help on this problem.