Page 1 of 1

SimpleGraph. How to put the text in parallel link?

PostPosted: January 2nd, 2009, 6:31 pm
by slavapro
help, please))))

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 15th, 2009, 8:12 am
by Kambiz
What do you mean? An image would be very helpful.

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 18th, 2009, 11:49 pm
by slavapro
Kambiz wrote:What do you mean? An image would be very helpful.


picture attached on message now)))

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 19th, 2009, 5:38 am
by Kambiz
I guess you don't use Caption property of the links, right?

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 19th, 2009, 12:18 pm
by slavapro
Kambiz wrote:I guess you don't use Caption property of the links, right?


Code: Select all
procedure TForm1.SimpleGraph1ObjectInitInstance(Graph: TSimpleGraph; {вставка объекта}
  GraphObject: TGraphObject);
begin
    if GraphObject is TGraphLink then    {участок}
    with TGraphLink(GraphObject) do
    begin
      pen.color:=clred;
      pen.width:=3;
      text:='';
      if (source<>nil) and (target<>nil)then text:=inttostr(source.id)+'-'+inttostr(target.id);
      text:=text+'0 0 0 0 0';
      hint:='';
      font.color:=clblue;
      font.Size:=10;
    end;
. . . . . .
end

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 19th, 2009, 3:28 pm
by Kambiz
Have you downloaded the component from delphiarea, or somewhere else?

Maybe I didn't get what you mean. Please, describe the problem. If you don't know English, describe it in your own language. Somehow I'll figure it out.

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 19th, 2009, 8:55 pm
by slavapro
Kambiz wrote:Have you downloaded the component from delphiarea, or somewhere else?

Maybe I didn't get what you mean. Please, describe the problem. If you don't know English, describe it in your own language. Somehow I'll figure it out.


Yes? i use simplegraph 2.6, In the demo program it works correctly. But in my code, the text is not displayed along the link, but only horizontally. How to make whatever conclusions parallel connection?

В Демо программе все работает правильно. Но в моем коде текст выводится не вдоль связи, а только горизонтально. Как сделать что бы текст выводился параллельно связи?

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 20th, 2009, 9:56 am
by Kambiz
This never happens on my machine.

What are versions of your Delphi and Windows? Please send me the .sg file of your graph too,

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 20th, 2009, 11:53 am
by slavapro
Kambiz wrote:This never happens on my machine.

What are versions of your Delphi and Windows? Please send me the .sg file of your graph too,


Delphi 7.0, Windows XP SP3

If you open my file in the demo program is still the text is not located along the links

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 20th, 2009, 2:50 pm
by Kambiz
Try to change the font. :-k Maybe the font you are using does not support rotation. :?

Re: SimpleGraph. How to put the text in parallel link?

PostPosted: January 20th, 2009, 3:34 pm
by slavapro
Kambiz wrote:Try to change the font. :-k Maybe the font you are using does not support rotation. :?


Yes!Thank you for helping!