Line Point series - hide line to horiz or vert axis

Ideas and wishes for TeeChart
Post Reply
SteveP
Advanced
Posts: 132
Joined: Sun Sep 07, 2003 4:00 am

Line Point series - hide line to horiz or vert axis

Post by SteveP » Fri Aug 19, 2005 4:24 pm

Could the ability to choose to which axis (horizontal or vertical) the lines from the series points are dropped to be selectable ? Currently there is a line drawn from each series point to both the horizontal and the vertical axis. The option to only draw to either of them could be useful.

Also, ability to place the marks to the side of the series points instead of above them, especialy when the line would have been specified to only be drawn to the vertical axis. In those cases, the line is a horizontal line and hence having the marks appear to its side instead of above the points makes sense. If the line is only drawn to the vertical axis and the bottom axis is inverted, then the marks should be placed towards the right of the points, in the same manner as what happens when a horizontal line series has its bottom axis inverted.

Also, could the lines of the line point series be individually colored ?

Thanks,

Steve

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

Post by Narcís » Mon Aug 22, 2005 10:43 am

Hi Steve,
Could the ability to choose to which axis (horizontal or vertical) the lines from the series points are dropped to be selectable ? Currently there is a line drawn from each series point to both the horizontal and the vertical axis. The option to only draw to either of them could be useful.
This is not possible for now. I've added your request to our wish-list to be considered for future releases.
Also, ability to place the marks to the side of the series points instead of above them, especialy when the line would have been specified to only be drawn to the vertical axis. In those cases, the line is a horizontal line and hence having the marks appear to its side instead of above the points makes sense. If the line is only drawn to the vertical axis and the bottom axis is inverted, then the marks should be placed towards the right of the points, in the same manner as what happens when a horizontal line series has its bottom axis inverted.
This is already available using custom marks:

Code: Select all

procedure TForm1.FormCreate(Sender: TObject);
var
  i: Integer;
  APosition:TSeriesMarkPosition;
begin
  Series1.FillSampleValues();
  Chart1.Draw();

  APosition:=TSeriesMarkPosition.Create;
  try
    for i:=0 to Series1.Count-1 do
    begin
      APosition.Custom:=True;
      APosition.LeftTop.X:=Series1.Marks.Positions[i].LeftTop.X;
      APosition.LeftTop.Y:=Series1.Marks.Positions[i].LeftTop.Y-35;
      Series1.Marks.Positions[i]:=APosition;
    end;
  finally
      APosition.Free;
  end;
end;
Also, could the lines of the line point series be individually colored ?
This is not possible, I've added that to our wish-list as well.
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

SteveP
Advanced
Posts: 132
Joined: Sun Sep 07, 2003 4:00 am

Post by SteveP » Mon Aug 22, 2005 2:23 pm

Narcis,

Your code for custom positioning marks does not result in certain properties of the marks being copied, such as frame or arrow color. Thus these items do not show. Also, the mark seems to be lower right justified instead of lower center since if its position in not changed, it appears to the left of the data value point.

This seems to work :

for i := 0 to series1.Marks.Positions.Count - 1 do
begin
series1.Marks.Positions.Position.Custom := true;
series1.Marks.Positions.Position.LeftTop.X := series1.Marks.Positions.Position.LeftTop.X - 10;
series1.Marks.Positions.Position.LeftTop.Y := series1.Marks.Positions.Position.LeftTop.Y + 22;
end;
series1.Repaint;

Steve

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

Post by Narcís » Mon Aug 22, 2005 3:01 pm

Hi Steve,
Your code for custom positioning marks does not result in certain properties of the marks being copied, such as frame or arrow color. Thus these items do not show.
Yes, custom marks are new marks and you should set all those properties.
Also, the mark seems to be lower right justified instead of lower center since if its position in not changed, it appears to the left of the data value point.
Yes, I just copied and pasted a snippet just to show you how to do that.
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