Ignore:
Timestamp:
Dec 22, 2016, 2:34:33 PM (7 years ago)
Author:
chronos
Message:
  • Fixed: Memory leaks introduced by TFColor. TFColor now use reference counting as descendant of IFColor.
  • Added: Line drawing for TFPixmap class.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/gbitmap/Packages/FastGraphics/ColorFormats/UColorGray1.pas

    r24 r25  
    4646    procedure Fill(Color: IBColor); override;
    4747    procedure Fill(Func: TGetColorPos); override;
     48    procedure Line(P1, P2: TPoint; Color: IBColor); override;
    4849    procedure PaintToCanvas(Canvas: TCanvas); override;
    4950    function GetDataSize: Integer; override;
     
    132133end;
    133134
     135procedure TBPixmapGray1.Line(P1, P2: TPoint; Color: IBColor);
     136begin
     137  Pixmap.Canvas.Pen.Color := (Color as TBColorGray1).Value;
     138  Pixmap.Canvas.Pen.MoveTo(P1);
     139  Pixmap.Canvas.Pen.LineTo(P2);
     140end;
     141
    134142procedure TBPixmapGray1.PaintToCanvas(Canvas: TCanvas);
    135143begin
Note: See TracChangeset for help on using the changeset viewer.