Formatting metafiles in TRichView
Posted: Mon May 29, 2006 8:53 am
Hi,
I load several metafiles into a RichView, page breaking each one so I have one metafile per page.
I want to reformat them to be correctly viewed (and printed) into a TRVPrintPreview (linked to a RVPrint) control. I've attempted several ways to do this but without success.The metafiles are always too much big in width (they are clipped on the right).
Could you help me?
Thanks.
Robert
I load several metafiles into a RichView, page breaking each one so I have one metafile per page.
Code: Select all
begin
TheRichView.Clear;
for i:=1 to pp do
begin
gr := TMetafile.Create;
pic.Picture.LoadFromFile('C:\Temp\'+WFilePrefix+Format('%4.4d',[i])+'.WMF');
pic.Width:=ThePreview.AreaWidth;
gr.Assign(pic.Picture);
TheRichView.AddPictureEx('',gr,0,rvvaBaseline);
TheRichView.AddBreak;
end;
end;
Could you help me?
Thanks.
Robert