Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing font on my CTreeCtrl – item

Status
Not open for further replies.

d00ape

Programmer
Apr 2, 2003
171
SE
I have overloaded the CTreeCtrl::OnCustomdraw ( NMHDR* pNMHDR, LRESULT* pResult )
Function and would like to make the item texts Bold.

Can I use the NMLVCUSTOMDRAW struct. I have tried looking in MSDN.

I successfully have changed the text color with the following code:

----------------------------
void MyTreeCtrl::OnCustomdraw ( NMHDR* pNMHDR, LRESULT* pResult )
{
NMLVCUSTOMDRAW* pLVCD = reinterpret_cast<NMLVCUSTOMDRAW*>( pNMHDR );
pLVCD->clrText = RGB( 210, 65, 20 );
}
----------------------------

Any suggestion how to change the font… ?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top