Article View: borland.public.cppbuilder.nativeapi
Article #6835Re: ImageList insert
From: xa
Date: Tue, 05 Apr 2005 00:06
Date: Tue, 05 Apr 2005 00:06
72 lines
3403 bytes
3403 bytes
When building an ImageList at runtime is there a quicker way rather than using the Add().. i have been loading 500 images of the same size 75x75 so they are quite small but the program slows dramatically while this is being done.. It might not help that i am having to call the images in from jpg first and assigning them to a bitmap prior to adding them to the list., but it still seems a bit slow building the list.. Any speeding up ideas very welcome.. "xa" <pageme@ntlworld.com> wrote in message news:42501739$1@newsgroups.borland.com... > Thanks... didn't know about replace.. > > "Vladimir Stefanovic" <antivari@po.sbb.co.yu> wrote in message > news:424fdfd4@newsgroups.borland.com... > > If I understoup the question well, what wrong with > > TCustomImageList::Replace() ? > > > > Replaces an image in the image list with a new image and mask. > > void __fastcall Replace(int Index, Graphics::TBitmap* Image, > > Graphics::TBitmap* Mask); > > > > > > Or the sequence of methods of TCustomImageList? > > > > 1) Adds an Image and its Mask to the image list object. > > int __fastcall Add(Graphics::TBitmap* Image, > > Graphics::TBitmap* Mask); > > > > 2) Deletes a particular image from the image list. > > void __fastcall Delete(int Index); > > > > 3) Moves a specified image to another position. > > void __fastcall Move(int CurIndex, int NewIndex); > > > > > > > > -- > > Best regards, > > Vladimir Stefanovic > > > > "xa" <pageme@ntlworld.com> wrote in message > > news:424fc6f2@newsgroups.borland.com... > > > Can anyone point me in the right direction for replacing an image in an > > > ImageList with another same size image. > > > > > > The Image list i use is created at runtime and the images are used for a > > > ListView...due to the time involved in loading the images into the > > > ImageList > > > i would like to be able to insert an edited image selection with the new > > > image without having to reload the entire list of images into the > > > ImageList > > > to re-index them.. the index of the images is tied to other data so i > cant > > > have it just remove the other image and use the Add() function as it > would > > > put out the other data indexes. > > > > > > I did notice HIDESBASE Insert method for inserting a bitmap into an > > > imagelist but not sure if this is the only way of doing it.. > > > > > > > > > > > > > > > > > >
Technical Details
Message-ID:
<4251d643$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news2.google.com!newsread.com!newsprint.newsread.com!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.usenet.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<424fc6f2@newsgroups.borland.com> <424fdfd4@newsgroups.borland.com> <42501739$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,ece920da0e48971e X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "xa" <pageme@ntlworld.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <424fc6f2@newsgroups.borland.com> <424fdfd4@newsgroups.borland.com> <42501739$1@newsgroups.borland.com> Subject: Re: ImageList insert Date: Tue, 5 Apr 2005 01:06:15 +0100 Lines: 74 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2720.3000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2739.300 NNTP-Posting-Host: 81.103.71.168 Message-ID: <4251d643$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1112659523 81.103.71.168 (4 Apr 2005 17:05:23 -0800) Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news2.google.com!newsread.com!newsprint.newsread.com!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.usenet.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail