Missing TextAlignment with footer

TeeChart for ActiveX, COM and ASP
Post Reply
Gottkehaskamp
Newbie
Newbie
Posts: 5
Joined: Fri Aug 02, 2013 12:00 am

Missing TextAlignment with footer

Post by Gottkehaskamp » Tue Jul 22, 2014 5:22 pm

Hello,

I'm trying to align some lines of footer text left. If I use:

m_ctrlTeeChart1.GetFooter().SetAlignment(taLeftJustify);

only the footer itself is on the left side of the chart, but the text in the footer is still centered. Therefor I miss a function like SetTextAlignment(...) as it is used for example with legends.

Is there any other way, to align the text left?

Regards
Raimund

Pep
Site Admin
Site Admin
Posts: 3272
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Re: Missing TextAlignment with footer

Post by Pep » Wed Jul 23, 2014 11:04 am

Hello Raimund,

which TeeChart ActiveX version are you using ?
I can't reproduce the problem by using the latest v2014.0.0.1 and following code :

Code: Select all

	m_chart.AddSeries(0);
	m_chart.Series(0).FillSampleValues(5);
	m_chart.GetFooter().GetText().SetText("hello World");
	m_chart.GetFooter().SetAlignment(0);

Gottkehaskamp
Newbie
Newbie
Posts: 5
Joined: Fri Aug 02, 2013 12:00 am

Re: Missing TextAlignment with footer

Post by Gottkehaskamp » Sun Jul 27, 2014 8:12 am

Hello Pep,

if there are more than one line, the text within the footer is centered. My code is

m_ctrlTeeChart1.GetFooter().GetFont().SetName("Arial");//neu 2013
m_ctrlTeeChart1.GetFooter().GetFont().SetItalic(false);
m_ctrlTeeChart1.GetFooter().GetFont().SetColor(RGB(0,0,0));
m_ctrlTeeChart1.GetFooter().SetAlignment(taLeftJustify);
m_ctrlTeeChart1.GetFooter().GetText().SetText("the footer ist on the left side\r\nbut\r\nthe text within the footer box is centered!");

The result is:
result.PNG
result.PNG (4.94 KiB) Viewed 11630 times
I miss a special function "TextAlignment()". With the teeEditor it is possible to left align the footer box and with another bottom to left align the text within the footer box.

Pep
Site Admin
Site Admin
Posts: 3272
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Re: Missing TextAlignment with footer

Post by Pep » Mon Jul 28, 2014 8:12 am

Hello Raimund,

yes, you're correct, due to the last v2014 changes and additions, the TextAligment property and others are hidden on the actual maintenance release.
I've just fixed that and now are available at runtime. There will be available for the next maintenance release, which will be available for download in a shorter time, in a few weeks. In meantime you could set it at designtime, via the Chart Editor.
Sorry for inconvenience this could be caused.

Post Reply