Teechart Legend Symbol for PieChart

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Luke
Newbie
Newbie
Posts: 68
Joined: Thu Oct 11, 2007 12:00 am

Teechart Legend Symbol for PieChart

Post by Luke » Wed Dec 10, 2008 2:03 pm

If I want to adjust the Border for the Symbols in the Legend it only ever adjusts the first item in the Series.

legend.Symbol.DefaultPen = false;
legend.Symbol.Pen.Visible = true;
legend.Symbol.Pen.Color = Color.Black;
legend.Symbol.Pen.Width = 1;

Does the same with the Charteditor.

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

Post by Narcís » Wed Dec 10, 2008 2:22 pm

Hi Luke,

Code below works fine for me here using latest TeeChart for .NET v3 release available at the client area It also works fine at designtime. Which version are you using?

Code: Select all

		public Form1()
		{
			InitializeComponent();
			InitializeChart();
		}

		void InitializeChart()
		{
			Steema.TeeChart.Styles.Line line1 = new Steema.TeeChart.Styles.Line(tChart1.Chart);

			line1.FillSampleValues();

			tChart1.Legend.Symbol.DefaultPen = false;
			tChart1.Legend.Symbol.Pen.Visible = true;
			tChart1.Legend.Symbol.Pen.Color = Color.Red;
			tChart1.Legend.Symbol.Pen.Width = 3; 
		}
Thanks in advance.
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

Luke
Newbie
Newbie
Posts: 68
Joined: Thu Oct 11, 2007 12:00 am

Post by Luke » Wed Dec 10, 2008 2:41 pm

Steema.TeeChart.Styles.Pie Pie = new Steema.TeeChart.Styles.Pie(tChart1.Chart);
for (int x = 0; x < 10; x++)
{
Pie.Add(x, "Label " + x.ToString(), Color.Aqua);
}
Pie.Pen.Visible = true;
tChart1.Legend.Symbol.DefaultPen = false;
tChart1.Legend.Symbol.Pen.Visible = true;
tChart1.Legend.Symbol.Pen.Color = Color.Red;
tChart1.Legend.Symbol.Pen.Width = 3;

try this if you set series pen.visible = false only the first is set ;-)

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

Post by Narcís » Wed Dec 10, 2008 3:12 pm

Hi Luke,

Thanks for the information. I could reproduce the issue here now and added it (TF02013646) to the defect list to be fixed.
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