home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / os / mswindo / programm / misc / 1439 < prev    next >
Encoding:
Text File  |  1992-08-21  |  1.5 KB  |  34 lines

  1. Newsgroups: comp.os.ms-windows.programmer.misc
  2. Path: sparky!uunet!decwrl!csus.edu!netcom.com!ekalenda
  3. From: ekalenda@netcom.com (Edward J Kalenda)
  4. Subject: Re: GDI: Foreground color and StretchBlt
  5. Message-ID: <g2_nf9#.ekalenda@netcom.com>
  6. Date: Fri, 21 Aug 92 19:45:01 GMT
  7. Organization: Netcom - Online Communication Services  (408 241-9760 guest) 
  8. References: <mikael.64.714410136@udac.uu.se>
  9. Lines: 23
  10.  
  11. From article <mikael.64.714410136@udac.uu.se>, by mikael@udac.uu.se (Mikael Lundgren):
  12. > First a short presentation  of my goal. I need to define a custom
  13. > raster opertion code in order to achieve a special effect in an application
  14. > we are working on. After doing some calculations I have decided that the 
  15. > code to use is 0x00b8074a. The idea is that i want to use a b/w bitmap as a 
  16. > kind of filter in order to put a color (specified in a brush) on a specific 
  17. > area of the screen. Now, the destination bitmap is a color bitmap, this 
  18. > MIGHT mean that the b/w bitmap will be converted to a color bitmap which in 
  19. > turn might affect the results I see on the screen.
  20. > "If StretchBlt must convert a monochrome bitmap to color, it sets white 
  21. > bits (1) to the background color and black bits (0) to the foreground color."
  22. > My question is: what is the "foreground color"? I cannot seem to find that 
  23. > info anywhere! I hope that this is a REALLY easy question to answer...
  24.  
  25. SetTextColor() sets the foreground color, SetBkColor() setss the background
  26. color. I think they return the color they were set to before the call.
  27. -- 
  28.  
  29. Ed
  30. ekalenda@netcom.COM
  31.