TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
-
OMP
- Newbie
- Posts: 21
- Joined: Mon Dec 10, 2012 12:00 am
Post
by OMP » Tue Jun 04, 2013 10:36 am
Dear,
I have an issue when I add more than one line of text to the series marks.
As you can see in the screenshot, part of the series mark is cut off.
The code I wrote to get this chart is the following:
Code: Select all
void barSeries1_GetSeriesMark(Steema.TeeChart.Styles.Series series, Steema.TeeChart.Styles.GetSeriesMarkEventArgs e)
{
e.MarkText = "SERIES MARK";
e.MarkText = "SERIES MARK\n Second line: " + e.ValueIndex;
}
public Form1()
{
InitializeComponent();
tChart1.Axes.Left.Automatic = true;
tChart1.Aspect.View3D = false;
tChart1.Legend.Visible = false;
Steema.TeeChart.Styles.Line line = new Steema.TeeChart.Styles.Line(tChart1.Chart);
line.FillSampleValues(10);
line.GetSeriesMark += new Steema.TeeChart.Styles.Series.GetSeriesMarkEventHandler(barSeries1_GetSeriesMark);
line.Marks.Visible = true;
}
-
Attachments
-
- Capture.PNG (26.86 KiB) Viewed 10153 times
-
Sandra
- Site Admin
- Posts: 3132
- Joined: Fri Nov 07, 2008 12:00 am
Post
by Sandra » Tue Jun 04, 2013 3:29 pm
Hello OMP,
I recommend you set Clip of Marks to false as do in next line of code:
Could you tell us if my suggestion help you to achieve as you want?
Thanks,
-
OMP
- Newbie
- Posts: 21
- Joined: Mon Dec 10, 2012 12:00 am
Post
by OMP » Fri Jun 07, 2013 8:56 am
If I set the Clip property to false, I don't see a label at all for my highest point, as you can see in the screenshot at point number 6.
I want to make sure that my labels are visible all the time.
If you change the chart to 3D, the label is visible. It is shown a little bit 'above' the chart, but if you switch to 2D, the label is not shown.
What can I do to have the label shown in all cases.
Thanks in advance,
Marijke
-
Attachments
-
- Capture2.PNG (44.85 KiB) Viewed 10109 times
-
Sandra
- Site Admin
- Posts: 3132
- Joined: Fri Nov 07, 2008 12:00 am
Post
by Sandra » Fri Jun 07, 2013 11:20 am
Hello OMP,
In your case, my recommendation is that uses Clip Marks property as false and increase the TopMargin, using next lines of code:
Code: Select all
Series1.Marks.Clip = false;
tChart1.Panel.MarginTop = 7;
Could you tell us if previous code help you to solve your problem?
Thanks,
-
OMP
- Newbie
- Posts: 21
- Joined: Mon Dec 10, 2012 12:00 am
Post
by OMP » Mon Jun 10, 2013 6:42 am
This has solved our problem.
Thank you very much,
Marijke
-
Sandra
- Site Admin
- Posts: 3132
- Joined: Fri Nov 07, 2008 12:00 am
Post
by Sandra » Mon Jun 10, 2013 10:56 am
Hello Marijke,
I am glad that you can solve the problem
Thanks,