Line problem (bug)

Posted:
June 21st, 2007, 8:14 pm
by Radek
There is a problem with line exactly horizontal or vertical, there is no hand to move this line. You can try it in your SGDemo.exe application. Select "Link/Line" and draw line exactly horizontal (for example from point 10, 10 to 100, 10), then click outside of the line! Now you can't move this line, becouse there is no hand on it.
Is there any way to resolve this problem ?

Posted:
June 22nd, 2007, 5:02 am
by Kambiz
I checked it out with v2.62 and didn't see any problem.


Posted:
June 22nd, 2007, 6:34 am
by Radek
This problem is in 2.62 but there is more detail:
- only where line is 1 pixel
- BeginStyle = none
- EndStyle = none (!)
and this linie must be exactly horizontal or vertical (NOT across)
Could you try again.

Posted:
June 22nd, 2007, 6:39 am
by Radek
Try to move this line ...

Posted:
June 22nd, 2007, 12:18 pm
by Kambiz
I could regenerate the bug.
To fix the problem, open SimpleGraph.pas and look for
- Code: Select all
procedure TGraphLink.QueryVisualRect(out Rect: TRect);
then after
- Code: Select all
Margin := Pen.Width div 2;
insert
- Code: Select all
if Margin = 0 then Margin := 1;
Thank you!