diff --git a/src/generic/treectlg.cpp b/src/generic/treectlg.cpp index 66822423d0..b0de2f9f2b 100644 --- a/src/generic/treectlg.cpp +++ b/src/generic/treectlg.cpp @@ -1021,6 +1021,12 @@ void wxGenericTreeCtrl::SetItemBold(const wxTreeItemId& item, bool bold) if ( pItem->IsBold() != bold ) { pItem->SetBold(bold); + + // recalculate the item size as bold and non bold fonts have different + // widths + wxClientDC dc(this); + CalculateSize(pItem, dc); + RefreshLine(pItem); } }