No, no, no.. we are all here for questions. Some to ask them , some to answer them. Or both. But don't get me wrong: I'm not complaining. On the contrary, I'm very grateful for the support I get here.
As for the second answer: I have not been able to get any WM_CTLCOLOR** to work for the treeview.
-Jay
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Maybe this is all crap, cause i have never colored a Tree View Control, but i know the existence of this macros:
TreeView_GetBkColor
TreeView_GetInsertMarkColor
TreeView_GetLineColor
TreeView_GetTextColor
TreeView_SetBkColor
TreeView_SetInsertMarkColor
TreeView_SetLineColor
TreeView_SetTextColor
There probably are more macros or messages you could use. I could find those doing a quick search on MSDN.
At the end of the page at the link above, theres a list of the Messages a Tree View Control processes, so you have to decide how to deal with each of them in order to set the appearance of your Tree View control.
I didnt look at it, but probably WM_PAINT or WM_DRAWITEM or something like that is there.
And sorry if you knew all that and this help was useless :) I know absolutely nothing about tree view controls.
Good luck,
/Effenberg
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
To change the text color in a tree view you can do something like this:
SendMessage(hTreeView, TVM_SETTEXTCOLOR, 0, (LPARAM) (COLORREF)RGB(0,0,255));
But that affects all of the text. I want to change it per item. I know it is possible, but how??
-Jay
I'll be damned. This happens all the time. I ask a question and nobody has the answer.
-Jay
The fact is, most have jobs and something else to do other then be here for questions.
http://sourceforge.net/forum/forum.php?thread_id=808331&forum_id=48211
No, no, no.. we are all here for questions. Some to ask them , some to answer them. Or both. But don't get me wrong: I'm not complaining. On the contrary, I'm very grateful for the support I get here.
As for the second answer: I have not been able to get any WM_CTLCOLOR** to work for the treeview.
-Jay
Maybe this is all crap, cause i have never colored a Tree View Control, but i know the existence of this macros:
TreeView_GetBkColor
TreeView_GetInsertMarkColor
TreeView_GetLineColor
TreeView_GetTextColor
TreeView_SetBkColor
TreeView_SetInsertMarkColor
TreeView_SetLineColor
TreeView_SetTextColor
There probably are more macros or messages you could use. I could find those doing a quick search on MSDN.
You probably knew all of them, anyway if you dont, youll find some Tree View info and examples here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/commctls/treeview/reflist.asp
At the end of the page at the link above, theres a list of the Messages a Tree View Control processes, so you have to decide how to deal with each of them in order to set the appearance of your Tree View control.
I didnt look at it, but probably WM_PAINT or WM_DRAWITEM or something like that is there.
And sorry if you knew all that and this help was useless :) I know absolutely nothing about tree view controls.
Good luck,
/Effenberg
Thanks Effenberg! There even was some example code on how to do it. It's not easy (and MFC) but I'll figure it out.
-Jay