Click here to Skip to main content
15,888,461 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: read stderr from console in Win32 Application Pin
sukem25-Oct-07 22:45
sukem25-Oct-07 22:45 
QuestionHow to send HTTP request with particular Agent name and get the response. Pin
Y K Kishore Kumar25-Oct-07 4:29
Y K Kishore Kumar25-Oct-07 4:29 
AnswerRe: How to send HTTP request with particular Agent name and get the response. Pin
led mike25-Oct-07 5:07
led mike25-Oct-07 5:07 
QuestionReport Generation in VC++ Pin
Shivarudrayya H25-Oct-07 3:35
Shivarudrayya H25-Oct-07 3:35 
AnswerRe: Report Generation in VC++ Pin
led mike25-Oct-07 4:13
led mike25-Oct-07 4:13 
QuestionDrawing WMF/EMF antialiased Pin
Alexandre GRANVAUD25-Oct-07 3:00
Alexandre GRANVAUD25-Oct-07 3:00 
Questionhi i want to color the cell of list control Pin
rajneshmalik25-Oct-07 2:30
rajneshmalik25-Oct-07 2:30 
AnswerRe: hi i want to color the cell of list control [modified] Pin
Force Code25-Oct-07 4:04
Force Code25-Oct-07 4:04 
Anything in Windows that there's not a documented interface for, you can usually accomplish through Windows subclassing.

In your case, to sketch out a solution, you would subclass the list control window, and then handle in all liklihood WM_PAINT. On that message, you would send LVM_GETITEMRECT to the list control window, and get the bounding rect of the list control cell you were interested in. Then just BitBlt whatever color you want to the hdc of the window, using the dimensions of the rect you retrieved (possibly using PATBLT for a ROP code, first setting the hdc brush to the appropriate color.) So that's the basic idea.

Actually, although I'm not sure I entirely understood you, the above solution might not work if you BitBlt to the cell and then the original WinProc writes text over it, as the textbackground color may be wrong, unless its being drawn transparent. Of course, there's SetBkMode to make the text background transparent, but I don't know how you get this to work for the hdc the original WndProc is writing to. It looks like you've got some work to do on your own, but its certainly not impossible. Also there's LVM_SETTEXTBKCOLOR, FWIW.

-- modified at 11:09 Thursday 25th October, 2007
AnswerRe: hi i want to color the cell of list control Pin
Roger Broomfield25-Oct-07 6:34
Roger Broomfield25-Oct-07 6:34 
GeneralRe: hi i want to color the cell of list control Pin
rajneshmalik29-Oct-07 23:31
rajneshmalik29-Oct-07 23:31 
GeneralRe: hi i want to color the cell of list control Pin
Roger Broomfield30-Oct-07 4:25
Roger Broomfield30-Oct-07 4:25 
AnswerRe: hi i want to color the cell of list control Pin
Nelek29-Oct-07 4:13
protectorNelek29-Oct-07 4:13 
GeneralRe: hi i want to color the cell of list control Pin
rajneshmalik29-Oct-07 23:28
rajneshmalik29-Oct-07 23:28 
QuestionAny good resource for learning windows drivers Pin
followait25-Oct-07 1:19
followait25-Oct-07 1:19 
AnswerRe: Any good resource for learning windows drivers Pin
JudyL_MD25-Oct-07 2:50
JudyL_MD25-Oct-07 2:50 
AnswerRe: Any good resource for learning windows drivers Pin
David Crow25-Oct-07 2:52
David Crow25-Oct-07 2:52 
Questionunusual problem Please help me Pin
Rahul Vaishnav25-Oct-07 0:57
Rahul Vaishnav25-Oct-07 0:57 
AnswerRe: unusual problem Please help me Pin
ThatsAlok25-Oct-07 2:17
ThatsAlok25-Oct-07 2:17 
QuestionAbout waveinopen Pin
minihotto25-Oct-07 0:29
minihotto25-Oct-07 0:29 
AnswerRe: About waveinopen Pin
Nishad S25-Oct-07 0:36
Nishad S25-Oct-07 0:36 
GeneralRe: About waveinopen Pin
minihotto25-Oct-07 0:40
minihotto25-Oct-07 0:40 
QuestionRe: About waveinopen Pin
Nishad S25-Oct-07 0:49
Nishad S25-Oct-07 0:49 
AnswerRe: About waveinopen Pin
minihotto25-Oct-07 0:56
minihotto25-Oct-07 0:56 
GeneralRe: About waveinopen Pin
Nishad S25-Oct-07 1:01
Nishad S25-Oct-07 1:01 
GeneralRe: About waveinopen Pin
minihotto25-Oct-07 1:18
minihotto25-Oct-07 1:18 

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.