Page 1 of 1

Chart.Graphics3D method signature changed in new release?

Posted: Thu Oct 25, 2007 4:04 pm
by 13046319
Hi,
With build 3.2.2763.26082 the Chart.Graphics3D class exposes the following method: public abstract void Rectangle(Brush b, Rectangle r); which we were calling in our code. With the most recent build 3.2.2831.26851 this method is no longer available and the change is not documented in the release notes... Why the change? How come it's not documented?

Thanks in advance,
Bill

Posted: Fri Oct 26, 2007 10:55 am
by narcis
Hi Bill,

I'd like to apologise for forgetting to document it.

Now you can do this:

Code: Select all

			((Steema.TeeChart.Drawing.Graphics3DGdiPlus)tChart1.Graphics3D).Graphics.FillRectangle(Brush b, Rectangle r);


or in the AfterDraw event this:

Code: Select all

			((Steema.TeeChart.Drawing.Graphics3DGdiPlus)g).Graphics.FillRectangle(Brush b, Rectangle r);
The reason for this method being removed it is because it was redundant.

Posted: Fri Oct 26, 2007 11:39 am
by narcis
Hi Bill,

For completeness, you could also do something like this:

Code: Select all

		void tChart1_AfterDraw(object sender, Steema.TeeChart.Drawing.Graphics3D g)
		{
			SolidBrush brush = new SolidBrush(Color.Red);
			ChartBrush cbrush = new ChartBrush(g.Chart, brush);
			g.Brush = cbrush;
			Rectangle rect = new Rectangle(0, 0, 100, 100);
			g.Rectangle(rect);
		}
Hope this helps!