Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


ID: 16539, Hatch brushes in TCanvas work incorrectly

by Vadim Komine Email: Anonymous


The hatch brushes in TCanvas work incorrectly if the brush color is set to clGray.
Download Details
FTP  download also available
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For C++Builder, Version 3.0  to 6.0 144 downloads
Copyright: All rights reserved


Size: 1,590 bytes
Updated on Fri, 28 Feb 2003 05:07:46 GMT
Originally uploaded on Thu, 13 Sep 2001 07:06:12 GMT
SHA1 Hash: E07D88FC51546229F4D441EE0ECCD545C60B4DD2
MD5 Hash: EB9AE4CB0E0B6818D02E11C661CAE2F5

    Explore the files in this upload

Description
The hatch brushes in TCanvas work incorrectly if the brush color is set to clGray.
Windows 9x doesn't draw the brush hatched if the background color is equal to the brush color. Therefore, the CreateBrush method of TCanvas set the background color for the hatch brush by the following way:

SetBkColor(FHandle, not ColorToRGB(Brush.Color));

However, this way does not work if the brush color is equal to clGray.

For more information, see http://www.mblabsoft.com

   Latest Comments  View All Add New

Move mouse over comment to see the full text

Server Response from: ETNACDC03