Changing to state of tree item to BOLD does not change the size of the displayed string.
(VS2008, MFC, feature-pack).
I created a CTreeCtrl and filled it with some data; the items are "drawn" dynamically with the handle of
and in the
, I set the item state to bold of certain items with :
SetItemState(hItem, TVIS_BOLD, TVIS_BOLD);
This does work most of the time when the tree is filled and I manually change the state of the certains other items, but when the tree is initialized, the first item that is set to bold have its text/label clipped.
It seems the "new" CTreeCtrl (common control ver. 6 ?) changes the behaviour of the custom drawing of the tree.
One solution found in the web, is to change the common control version of the Tree to 5 with the message CCM_SETVERSION. but this does not seems to work.
I send the message to the tree just after I create it.
Anyone have issues with custom drawing a tree control ?
: I had to reset the string of the item after the bold state was set to the item.