[lazarus] New Bug Entered
Mattias Gaertner
nc-gaertnma at netcologne.de
Sat Nov 22 20:11:59 EST 2003
On Sun, 9 Nov 2003 07:31:17 -0500 (EST) bugtracker at miraclec.com wrote:
>
> Title: IDE: SnapToGrid BugFix
>
> Entered by: Claude Rieth
>
> To obtain REAL snap to grid and not only modulo gridsize function, the
> following patch needs to be applied (gives behaviour similar to delphi)
>
> controlselection.pp
>
> function ...FindNearestSnapRight
> .
> .
> FindNearestGridX(NearestRight);
> //add the following
> if NearestRight.Valid then
> NearestRight.Nearest:=NearestRight.Nearest+1;
The snapping seems to work correct. The grid leftmost, topmost pixel is
painted at 0,0 and the grid snaps to 0,0.
What does Delphi do?
Mattias
> //end add
>
> function ...FindNearestSnapBottom
> .
> .
> FindNearestGridY(NearestBottom);
> //add the following
> if NearestBottom.Valid then
> NearestBottom.Nearest:=NearestBottom.Nearest+1;
> //end add
>
>
>
>
>
> _________________________________________________________________
> To unsubscribe: mail lazarus-request at miraclec.com with
> "unsubscribe" as the Subject
> archives at http://www.lazarus.freepascal.org/mailarchives
--
More information about the Lazarus
mailing list