Oh.
:-[
Michael Van Canneyt wrote:
On Fri, 29 Dec 2006, Dave Coventry wrote:
Hi,
If I set the size of the TBitmap in the FormCreate procedure rather than the
FormResize procedure, then the error does not arise.
In other words, if I have the following:
//~~~~~~~~~~~~~~~~~~~~~~~ snip ~~~~~~~~~~~~~~~~~~~~~~~
BufferBitMap:=TBitMap.Create;
BufferBitMap.Width:=Image1.Width;
BufferBitMap.Height:=Image1.Height;
//~~~~~~~~~~~~~~~~~~~~~~~ snip ~~~~~~~~~~~~~~~~~~~~~~~
in the same procedure rather than splitting it up over 2 different procedures,
then I don't get the SIGSEGV error.
That's because the OnResize method is called before OnCreate.
Michael.
Dave Coventry wrote:
Marc Weustink wrote:
Can you give us a little code sample ?
Marc
Yes, certainly:
//~~~~~~~~~~~~~~~~~~~~~~~ snip ~~~~~~~~~~~~~~~~~~~~~~~
var
BufferBitMap:TBitmap;
procedure TForm1.FormCreate(Sender: TObject);
begin
BufferBitMap:=TBitMap.Create;
end;
procedure TForm1.FormResize(Sender: TObject);
begin
BufferBitMap.Width:=Image1.Width;
BufferBitMap.Height:=Image1.Height;
end;
//~~~~~~~~~~~~~~~~~~~~~~~ snip ~~~~~~~~~~~~~~~~~~~~~~~
--
Dave Coventry
Tel: +27(0)31 3092301
Fax: +27(0)31 3092301
Cell: +27(0)82 3685983
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives
--
Dave Coventry
Tel: +27(0)31 3092301
Fax: +27(0)31 3092301
Cell: +27(0)82 3685983
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives