Page 1 of 1
borders at tchart
Posted: Fri Apr 17, 2015 7:51 am
by 15670445
Hi,
In the attached file you will see a part of a tchart with a distinct black border surrounding the image.
I have tried to remove this border using the code:
Code: Select all
Chart.Panel.Bevel.Outer = Steema.TeeChart.Drawing.BevelStyles.None;
However, it does not help - the black border is still there. What else can I do to remove that border??
Re: borders at tchart
Posted: Fri Apr 17, 2015 8:14 am
by narcis
Hi Friis,
Using this code snippet:
Code: Select all
tChart1.Series.Add(new Steema.TeeChart.Styles.Line()).FillSampleValues();
tChart1.Panel.Pen.Visible = false;
tChart1.Panel.Bevel.Inner = Steema.TeeChart.Drawing.BevelStyles.None;
tChart1.Panel.Bevel.Outer = Steema.TeeChart.Drawing.BevelStyles.None;
in an empty chart I get this:
- ChartNoPanelPen.jpg (54.82 KiB) Viewed 10968 times
you can also try hiding the chart walls:
If the problem persists at your end please attach a simple example project we can run "as-is" to reproduce the problem here.
Re: borders at tchart
Posted: Fri Apr 17, 2015 8:30 am
by 15670445
Hi,
I have attached an image generated in the following code.
I have taken the image generated below and then inserted the graph on a white blank page in windows Paint.
as you will see, a thin black line is still present??
Code: Select all
public Form1()
{
InitializeComponent();
tChart1.Series.Clear();
tChart1.Series.RemoveAllSeries();
tChart1.Tools.Clear();
tChart1.Axes.Left.Labels.Items.Clear();
tChart1.BackColor = Color.White;
tChart1.Walls.Back.Gradient.Visible = false;
tChart1.Walls.Back.Color = Color.White;
tChart1.Walls.Bottom.Gradient.Visible = false;
tChart1.Walls.Bottom.Color = Color.White;
tChart1.Panel.Gradient.Visible = false;
tChart1.Panel.Color = Color.White;
tChart1.Aspect.View3D = false;
tChart1.Walls.Visible = false;
tChart1.Panel.Pen.Visible = false;
tChart1.Panel.Bevel.Inner = Steema.TeeChart.Drawing.BevelStyles.None;
tChart1.Panel.Bevel.Outer = Steema.TeeChart.Drawing.BevelStyles.None;
tChart1.Panel.Bevel.Width = 0;
tChart1.Axes.Left.Automatic = true;
tChart1.Axes.Bottom.Automatic = true;
tChart1.Axes.Left.Title.Caption = "";
tChart1.Axes.Bottom.Title.Caption = "";
tChart1.Header.Text = "";
tChart1.Legend.Visible = false;
tChart1.Legend.Shadow.Visible = false;
tChart1.Legend.Font.Size = 14;
tChart1.Legend.Symbol.Width = 50;
tChart1.Legend.Symbol.Squared = true;
if (tChart1.Axes.Custom.Count > 0)
{
tChart1.Axes.Custom.Clear();
}
tChart1.Export.Image.Bitmap.Save(@"C:\Temp\jkhfw.bmp");
}
Re: borders at tchart
Posted: Fri Apr 17, 2015 8:33 am
by 15670445
... and by the way - thank you for a VERY fast reply
Re: borders at tchart
Posted: Fri Apr 17, 2015 8:44 am
by narcis
Hi Friis,
You're very welcome.
In that case this is the same problem
discussed here.
Which in your case can be solved like this:
Code: Select all
tChart1.Clear();
tChart1.BackColor = Color.White;
tChart1.Panel.Gradient.Visible = false;
tChart1.Panel.Color = Color.White;
tChart1.Aspect.View3D = false;
tChart1.Walls.Visible = false;
tChart1.Panel.Pen.Visible = false;
tChart1.Panel.Bevel.Inner = Steema.TeeChart.Drawing.BevelStyles.None;
tChart1.Panel.Bevel.Outer = Steema.TeeChart.Drawing.BevelStyles.None;
tChart1.Panel.Bevel.Width = 0;
tChart1.Header.Text = "";
tChart1.Legend.Visible = false;
var bufferStyle = tChart1.Graphics3D.BufferStyle;
tChart1.Graphics3D.BufferStyle = Steema.TeeChart.Drawing.BufferStyle.None;
tChart1.Export.Image.Bitmap.Save(@"C:\Temp\jkhfw.bmp");
tChart1.Graphics3D.BufferStyle = bufferStyle;
Re: borders at tchart
Posted: Fri Apr 17, 2015 9:20 am
by 15670445
Super - this works fantastic