🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.ms-windows.programmer.tools
Article #317

BWCCGetPattern()

#317
From: Allen Carr (NW1:2-1):-2838
Date: Wed, 26 Aug 1992 14:32
25 lines
1204 bytes
I wanted to create a window which used BCW's custom controls, with the 
pretty background. I created a class THWindow which defined the following 
virtual method:
	void THWindow::GetWindowClass(WNDCLASS& AClass) {
		TWindow::GetWindowClass(AClass);
		AClass.hbrBackground = BWCCGetPattern();
	}

The first time this program was run, everything was OK. On exiting any other 
Borland product which used BWCC lost their background. 

My reasoning for using BWCCGetPattern() was that it returned an HBRUSH so it 
should have worked with WNDCLASS.hbrBackground.

Any offers ??

I have found that using
	AClass.lpfnWndProc = BWCCDefWindowProc;
instead of
	AClass.hbrBackground = BWCCGetPattern();
seems to overcome the problem.

alan carr

email: carr@scinet.up.ac.za
Technical Details
Message-ID: <carr.7@scinet.up.ac.za>
Path: arc1-ca.pugleaf.net!sparky!uunet!psgrain!hippo!ford.ee.up.ac.za!carr.up.ac.za!carr

Show Full Headers
Complete Article Headers
Newsgroups: comp.os.ms-windows.programmer.tools
Path: arc1-ca.pugleaf.net!sparky!uunet!psgrain!hippo!ford.ee.up.ac.za!carr.up.ac.za!carr
From: carr@scinet.up.ac.za ( Allen Carr (NW1:2-1):-2838)
Subject: BWCCGetPattern()
Sender: news@ford.ee.up.ac.za (NetNews Daemon)
Message-ID: <carr.7@scinet.up.ac.za>
Date: Wed, 26 Aug 1992 14:32:59 GMT
Organization: Gold Fields Computer Centre for Education
Keywords: BC++ 3.1
Lines: 25