Changeset 62 for trunk/Packages/Common
- Timestamp:
- Nov 25, 2020, 4:25:09 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Packages/Common/UMetaCanvas.pas
r60 r62 6 6 7 7 uses 8 Classes, SysUtils, Graphics, Contnrs, Types ;8 Classes, SysUtils, Graphics, Contnrs, Types, fgl; 9 9 10 10 type … … 17 17 procedure Zoom(Factor: Double); virtual; 18 18 procedure Move(Delta: TPoint); virtual; 19 end; 20 21 TCanvasObjects = class(TFPGObjectList<TCanvasObject>) 19 22 end; 20 23 … … 133 136 procedure DoLineTo(X, Y: Integer); override; 134 137 public 135 Objects: T ObjectList;138 Objects: TCanvasObjects; 136 139 procedure FillRect(const ARect: TRect); overload; override; 137 140 procedure FillRect(X1,Y1,X2,Y2: Integer); overload; … … 154 157 end; 155 158 159 156 160 implementation 157 161 … … 198 202 Pen.Free; 199 203 Brush.Free; 200 inherited Destroy;204 inherited; 201 205 end; 202 206 … … 228 232 destructor TCanvasStretchDraw.Destroy; 229 233 begin 230 inherited Destroy;234 inherited; 231 235 end; 232 236 … … 264 268 Pen.Free; 265 269 Brush.Free; 266 inherited Destroy;270 inherited; 267 271 end; 268 272 … … 304 308 Brush.Free; 305 309 Pen.Free; 306 inherited Destroy;310 inherited; 307 311 end; 308 312 … … 336 340 begin 337 341 Pen.Free; 338 inherited Destroy;342 inherited; 339 343 end; 340 344 … … 375 379 Pen.Free; 376 380 Brush.Free; 377 inherited Destroy;381 inherited; 378 382 end; 379 383 … … 408 412 Brush.Free; 409 413 Font.Free; 410 inherited Destroy;414 inherited; 411 415 end; 412 416 … … 633 637 begin 634 638 for I := 0 to Objects.Count - 1 do 635 TCanvasObject(Objects[I]).Paint(Canvas);639 Objects[I].Paint(Canvas); 636 640 end; 637 641 … … 641 645 begin 642 646 for I := 0 to Objects.Count - 1 do 643 TCanvasObject(Objects[I]).Zoom(Factor);647 Objects[I].Zoom(Factor); 644 648 end; 645 649 … … 649 653 begin 650 654 for I := 0 to Objects.Count - 1 do 651 TCanvasObject(Objects[I]).Move(Delta);655 Objects[I].Move(Delta); 652 656 end; 653 657 … … 656 660 inherited; 657 661 FPenPos := Point(0, 0); 658 Objects := T ObjectList.Create;662 Objects := TCanvasObjects.Create; 659 663 end; 660 664 … … 662 666 begin 663 667 Objects.Free; 664 inherited Destroy;668 inherited; 665 669 end; 666 670
Note:
See TracChangeset
for help on using the changeset viewer.