Article View: borland.public.cppbuilder.nativeapi
Article #10953Re: FloodFill Problems
From: Eelke Klein
Date: Mon, 08 Mar 2004 07:37
Date: Mon, 08 Mar 2004 07:37
28 lines
1978 bytes
1978 bytes
Giovanni Lazzarini wrote: > Hi all, > I try to use in my windows area FillRect(...) and FloodFill(...) in a main > form. > When I move a new windows form on this region FillRect works good behind new > windows but FloodFill doesn't: it paints only a region part with new Brush > color, the rest is painted with default one. > I tried to use method in canvas class and API too with the same result. > Any Idea? > > First you should use ExtFloodFill in 32-bits programs FloodFill is for compatibility with 16-bit windows. From the MSDN: The FloodFill function fills an area of the display surface with the current brush. The area is assumed to be bounded as specified by the crFill parameter. My guess it fills only a region because it encountered the specified border color. FillRect on the other hand allways fills the specified rectangular region. Use FloodFill only when you have to fill a non-rectangular area for rectangular areas FillRect is much faster. Eelke
Technical Details
Message-ID:
<404c22d7$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<404b4ae2$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,405417ddd7f666d5 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2004-03-07 23:39:30 PST Date: Mon, 08 Mar 2004 08:37:11 +0100 From: Eelke Klein <e.klein@mplussoftware.nl> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5) Gecko/20031007 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: borland.public.cppbuilder.nativeapi Subject: Re: FloodFill Problems References: <404b4ae2$1@newsgroups.borland.com> In-Reply-To: <404b4ae2$1@newsgroups.borland.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 81.58.1.162 Message-ID: <404c22d7$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1078731479 81.58.1.162 (7 Mar 2004 23:37:59 -0800) Lines: 29 Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!fu-berlin.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail