TMetafile Canvas && TMetafile lazarus / 7-LCL ---------------------------------------------------------------------- lfrodrigues · 2006-11-18 14:20 Hello, I've used Delphi 3-5 some years ago. Now at my current job I have to transform a windows only (Delphi 3) application into a multiplatform application. I've ported almost everything (excluding the use of TMetafile and Metafile Canvas). This was used  to create one image for each page for pintpreview and print (using TPrinter). Does anyone know how I can convert this to Lazarus? Best regards, Luis ---------------------------------------------------------------------- felipemdc · 2006-11-23 16:19 Metafile is Windows specific. Can´t you use the printer canvas directly? Without TMetafile. What functions from metafile do you need and cannot use on a normal canvas? ---------------------------------------------------------------------- lfrodrigues · 2006-11-23 18:43 I would like to user tcanvas but it does not work, for example I have this: var a:tcanvas; begin a := tcanvas.Create; a.TextOut(0,0,'ols'); a.destroy; it complains canvas does not allow drawing. I haven't worked in delphi for quite some some and don't remenber how to make this work (if it works). I need to draw to a canvas so I can make a printpreview. Maybe you can help me. Best regards ---------------------------------------------------------------------- theo · 2006-11-23 19:27 Try Printer.Canvas ---------------------------------------------------------------------- felipemdc · 2006-11-23 21:51 Quote from: "lfrodrigues"I need to draw to a canvas so I can make a printpreview. To make a print preview simply drop any component with a canvas, like a paintbox or a panel and draw on that. (MyPaintBox.Canvas or MyPanel.Canvas). When you actually go to print, use TPrinter.Canvas and do the same drawing procedures. ---------------------------------------------------------------------- lfrodrigues · 2006-11-28 01:36 Thanks for the replys.