Recent

Author Topic: TfrPictureView question  (Read 2910 times)

xinyiman

  • Hero Member
  • *****
  • Posts: 2256
    • Lazarus and Free Pascal italian community
TfrPictureView question
« on: July 26, 2012, 10:37:50 am »
In LazReport I want to center an image inside the component TfrPictureView. Who can tell me how? Plus I want to assign them: AllFrames line
Win10, Ubuntu and Mac
Lazarus: 2.1.0
FPC: 3.3.1

xinyiman

  • Hero Member
  • *****
  • Posts: 2256
    • Lazarus and Free Pascal italian community
Re: TfrPictureView question
« Reply #1 on: July 26, 2012, 10:46:30 am »
My Code:

procedure TForm1.Button1Click(Sender: TObject);
var
  Foto : TfrPictureView;
begin
  frReport1.Pages.Clear;
  frReport1.Pages.Add();
  Foto := TfrPictureView.Create;

  Foto.width  := 100;
  Foto.Height := 100;
  Foto.Left   := 10;
  Foto.Top    := 40;
  Foto.Stretched:=true;
  Foto.Picture.LoadFromFile(Application.Location + 'app.bmp');
  frReport1.Pages[0].Objects.Add(Foto);

  frReport1.ShowReport;
end;
Win10, Ubuntu and Mac
Lazarus: 2.1.0
FPC: 3.3.1

 

TinyPortal © 2005-2018