VoyForums

Login ] [ Contact Forum Admin ] [ Main index ] [ Post a new message ] [ Search | Check update time | Archives: 1[2]345678910 ]


[ Next Thread | Previous Thread | Next Message | Previous Message ]

Date Posted: 05:28:41 03/25/04 Thu
Author: Ralph
Subject: Re: Assigning a List of TMetaFiles to a ImageScrollBox
In reply to: Ralph 's message, "Assigning a List of TMetaFiles to a ImageScrollBox" on 11:43:04 03/22/04 Mon

BTW: This is how I tried to do it:

var
mfOutput: TMetaFile;
Rect: TRect;
nCounter: Integer;

for nCounter := 0 to (FList.Count - 1) do
begin
// ***************************************
// go through the list page by page
// ***************************************
mfOutput := TMetaFile(FList.Items[nCounter]);
mfOutput.MMWidth := GB_TIFWIDTH;
mfOutput.MMHeight := GB_TIFHEIGHT;

// ***************************************
// prepare a new page in ImageScrollBox
// THIS THROWS AN ERROR
// ***************************************
FImageScrollBox.Graphic.NewImage(2100, 2990, ifBlackWhite, nil, 300, 300);

// ***************************************
// fill the canvas with a white rectangle
// ***************************************
Rect.Left := 0;
Rect.Top := 0;
Rect.Right := 2100;
Rect.Bottom := 2990;
FImageScrollBox.Graphic.Canvas.Brush.Color := clWhite;
FImageScrollBox.Graphic.Canvas.FillRect(Rect);

// ***************************************
// draw the page on ScrollBox.Canvas
// ***************************************
FImageScrollBox.Graphic.Canvas.Draw(0, 0, mfOutput);
end;

[ Next Thread | Previous Thread | Next Message | Previous Message ]


Replies:


[ Contact Forum Admin ]


Forum timezone: GMT-5
VF Version: 3.00b, ConfDB:
Before posting please read our privacy policy.
VoyForums(tm) is a Free Service from Voyager Info-Systems.
Copyright © 1998-2019 Voyager Info-Systems. All Rights Reserved.