Click here to Skip to main content
15,921,212 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: ADODB pointer Pin
_crs_5-Aug-03 23:07
_crs_5-Aug-03 23:07 
GeneralConverting hexadecimal to decimal in C++ Pin
Member 1609885-Aug-03 22:15
Member 1609885-Aug-03 22:15 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
Chao Zuo5-Aug-03 22:35
Chao Zuo5-Aug-03 22:35 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
RChin5-Aug-03 22:36
RChin5-Aug-03 22:36 
GeneralRe: Converting hexadecimal to decimal in C++ Pin
Toni785-Aug-03 22:47
Toni785-Aug-03 22:47 
Generala clipboard question Pin
Chao Zuo5-Aug-03 21:44
Chao Zuo5-Aug-03 21:44 
GeneralCBitmapButton Pin
Marissa1825-Aug-03 21:24
Marissa1825-Aug-03 21:24 
GeneralRe: CBitmapButton Pin
Toni785-Aug-03 21:41
Toni785-Aug-03 21:41 
I don't know the exact grey color of buttons but I can tell you this much. What you are looking for might not be the best solution. In Windows, the default colors can be changed thus making your buttons look awkward. You have no way of knowing before hand what the background color would be. If you implement a bitmap button and set its background color to the dialog box color, it might work on your system, but it might not work on other systems.
To draw a bitmap button with transparent background you need to use a mask when painting the bitmap. So you need to have two bitmaps, one that stores the normal image and the other one that has the mask. A mask is nothing but an image that corresponds to the original but the background is white and the foreground is black. You need to perform the following operations:
1. Output the normal bitmap by XOR-ing it with the target device
2. Output the mask bitmap by AND-ing it with the target device at the exact location of the original bitmap.
3. Output the normal bitmap by XOR-ing it with the target device.
At the end you will have a transparent button.

// Afterall, I realized that even my comment lines have bugs

When one cannot invent, one must at least improve (in bed).-My latest fortune cookie
GeneralRe: CBitmapButton Pin
Marissa1825-Aug-03 21:43
Marissa1825-Aug-03 21:43 
GeneralRe: CBitmapButton Pin
Toni785-Aug-03 22:05
Toni785-Aug-03 22:05 
QuestionWhat is wrong in this piece of code... Pin
Exceter5-Aug-03 21:20
Exceter5-Aug-03 21:20 
AnswerRe: What is wrong in this piece of code... Pin
Toni785-Aug-03 21:51
Toni785-Aug-03 21:51 
GeneralRe: What is wrong in this piece of code... Pin
Exceter5-Aug-03 22:23
Exceter5-Aug-03 22:23 
GeneralRe: What is wrong in this piece of code... Pin
Toni785-Aug-03 22:44
Toni785-Aug-03 22:44 
GeneralRe: What is wrong in this piece of code... Pin
Exceter5-Aug-03 23:15
Exceter5-Aug-03 23:15 
GeneralRe: What is wrong in this piece of code... Pin
Steve S5-Aug-03 23:25
Steve S5-Aug-03 23:25 
GeneralRe: What is wrong in this piece of code... Pin
Exceter5-Aug-03 23:43
Exceter5-Aug-03 23:43 
QuestionWhat is wrong in this piece of code... Pin
Exceter5-Aug-03 21:20
Exceter5-Aug-03 21:20 
AnswerRe: What is wrong in this piece of code... Pin
Alexander M.,6-Aug-03 0:01
Alexander M.,6-Aug-03 0:01 
Questionwhat is the message generated? Pin
BK Pradeep5-Aug-03 21:17
BK Pradeep5-Aug-03 21:17 
AnswerRe: what is the message generated? Pin
Fredrik Skog6-Aug-03 0:50
Fredrik Skog6-Aug-03 0:50 
GeneralTransparent gradient shading Pin
lob5-Aug-03 21:08
lob5-Aug-03 21:08 
GeneralRe: Transparent gradient shading Pin
PJ Arends5-Aug-03 22:56
professionalPJ Arends5-Aug-03 22:56 
GeneralRe: Transparent gradient shading Pin
lob5-Aug-03 23:04
lob5-Aug-03 23:04 
QuestionQuestion about new? Pin
pani685-Aug-03 19:49
pani685-Aug-03 19:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.