<html><div style='background-color:'><DIV class=RTE>
<P>1) Its actually COLOR<STRONG>R</STRONG>EF (2 R's). Just include windows.h, and don't compile for console ( set it in the Dev-C++ options, or pass -mwindows to gcc/ g++ at the commandline ), and you should be fine. </P>
<P>2) Ususally, we try to find out which library contains the function we are using ( to stop linker errors ), not find out all the functions in a library. Anytime you are learning a new topic ( e.g windows programming ), whatever tutorial you use usually tells you what libraries you need to link to, in order to prevent linking errors. MSDN (<A href="http://msdn.microsoft.com">http://msdn.microsoft.com</A>) is a good source for info on windows programming. It tells you what headers and libraries are required for a particular function. A simple translation (e.g instead of gdi32.lib, we use -lgdi32) is all that is needed to compile it successfully in Dev-C++.</P>
<P>----Original Message Follows---- </P></DIV>
<DIV></DIV>From: "Brian Downing" <Bri...@ms...>
<DIV></DIV>To: "dev-cpp-users" <dev...@li...>
<DIV></DIV>Subject: [Dev-C++] COLOREF, libraries
<DIV></DIV>Date: Sat, 5 Jun 2004 08:47:28 -0700
<DIV></DIV>MIME-Version: 1.0
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<P> </P>
<P>I need to use COLOREF to paint my windows background but I don't think I'm linking the right library. Two questions: </P>
<DIV></DIV>
<DIV></DIV>Which library or header should I include/link to for access to COLOREF? I'm already linking to lgdi32.
<DIV></DIV>
<DIV></DIV>How do I know what each library contains when I'm looking for a function?
<DIV></DIV>
<DIV></DIV>Thanks, Brian
<DIV></DIV></div><br clear=all><hr>MSN 8 helps <a href="http://g.msn.com/8HMBEN/2743??PS=47575">ELIMINATE E-MAIL VIRUSES. </a> Get 2 months FREE*.</html>
|