Board index » delphi » Drawing to many TImages in turn
Patrick Robinson
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
|
Patrick Robinson
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
Drawing to many TImages in turn
Hi All,
My problem is this: I have an array of "images" (actually the instructions to draw the images) for Ndx := 0 to ... do Image0.Canvas := Array[0] Is this possible - can i "point" to each TImage component by some kind of Regards PX |
Gordon Whitt
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
Re:Drawing to many TImages in turnIn article <88a6l6$bq...@lure.pipex.net>, "Patrick Robinson" Quote<mak...@dial.pipex.com> writes: TImages in an array and then reference them as you would any other array. You need to create them and set propertys at run time of course but it does mean you can create them _only_ if you need them and free them as (not!) required. An array of TImage is just an array of pointers until they've been created so even if you declare a quite big array it still isn't going to take up much memory. If they are all the same regarding propertys then derive a new TImage and set the default propertys to whatever you want and create an array of TYourImage instead. type var Once you've created them just access them as you would any other array. You Gordon. MGCSoft |
VBDi
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
Re:Drawing to many TImages in turnIm Artikel <20000215041144.16165.00000...@nso-bj.aol.com>, gwhit41...@aol.com (Gordon Whittam) schreibt: Quote>You need to create them and set propertys at run time bitmap resource. But how to create and add bitmap resources to a unit? DoDi |
Bj?rge S?the
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
Re:Drawing to many TImages in turnVBDis skrev i meldingen <20000215085649.02091.00000...@nso-fa.aol.com>... Quote>Im Artikel <20000215041144.16165.00000...@nso-bj.aol.com>, Quote>(Gordon Whittam) schreibt: the .dfm format) 2) If you're on NT, you may add resources to an existing .dll or .exe using UpdateResource() API. 3) TImageList... -- |
Gordon Whitt
![]() Delphi Developer |
Sat, 03 Aug 2002 03:00:00 GMT
Re:Drawing to many TImages in turnIn article <20000215085649.02091.00000...@nso-fa.aol.com>, vb...@aol.com Quote(VBDis) writes: The resource (Bitmaps.res) was created in the image editor, leaving the names Gordon const TImageArray = array[0..MaxImages-1] of TMyImage; var implementation {$R *.DFM} constructor TMyImage.create(aOwner: TComponent); procedure TForm1.FormCreate(Sender: TObject); MGCSoft |
VBDi
![]() Delphi Developer |
Sun, 04 Aug 2002 03:00:00 GMT
Re:Drawing to many TImages in turnIm Artikel <Rbeq4.292$Po1.4...@news1.online.no>, "Bj?rge S?ther" <REMOVE_bsaet...@online.no> schreibt: Quote>3) TImageList... object. But what if another project does NOT include that form? Clarification: My problem arises from a non-form unit, which does not normally DoDi |