Mark Font Color Question

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
blueday321
Newbie
Newbie
Posts: 10
Joined: Mon Jun 20, 2005 4:00 am

Mark Font Color Question

Post by blueday321 » Tue Feb 28, 2006 12:31 am

Image

I wants putting in Mark Font-Color..

And Mark Text (ex: 7Count) wants comes to seem..

=======================================
pie1.AutoMarkPosition = true;
pie1.Marks.Style = Steema.TeeChart.Styles.MarksStyles.Value;
pie1.Marks.Callout.Arrow.Visible = false;
pie1.Marks.Transparent = true;
pie1.Marks.Color = Color.FromArgb(154, 123, 96);

But does not become the application with only this..



In me it informs a method and it is different..

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

Post by Narcís » Tue Feb 28, 2006 9:46 am

Hi WISEfn,

To set the marks font color you need to use pie1.Marks.Font.Color instead of pie1.Marks.Color. This is the working code:

Code: Select all

        private void Form1_Load(object sender, EventArgs e)
        {
            pie1.FillSampleValues();
            pie1.AutoMarkPosition = true;
            pie1.Marks.Style = Steema.TeeChart.Styles.MarksStyles.Value;
            pie1.Marks.Callout.Arrow.Visible = false;
            pie1.Marks.Transparent = true;
            pie1.Marks.Font.Color = Color.FromArgb(154, 123, 96); 
        }
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

blueday321
Newbie
Newbie
Posts: 10
Joined: Mon Jun 20, 2005 4:00 am

Thanks it gives in reply.

Post by blueday321 » Wed Mar 01, 2006 2:23 am

Thanks it gives in reply.

When wanting changing the label_Item in the Mark, it does how?

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 Mar 01, 2006 8:48 am

Hi WISEfn,

You can do it when populating the series using any of the Add method overrides that allow setting the marks content:

Code: Select all

		private void Form1_Load(object sender, System.EventArgs e)
		{
			pie1.Add(5,"Pie Slice 1");
			pie1.Add(7,"Pie Slice 2");
			pie1.Add(2,"Pie Slice 3");
		}
Or using series GetMarkText event:

Code: Select all

		private void Form1_Load(object sender, System.EventArgs e)
		{
			pie1.Add(5);
			pie1.Add(7);
			pie1.Add(2);
		}

		private void pie1_GetSeriesMark(Steema.TeeChart.Styles.Series series, Steema.TeeChart.Styles.GetSeriesMarkEventArgs e)
		{
			e.MarkText="Pie Slice "+(e.ValueIndex+1).ToString();
		}
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