diff --git a/docs/changes.txt b/docs/changes.txt index 62cd9e56d7..41e4a7668b 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -130,6 +130,7 @@ All (GUI): wxHtmlListBox::OnLinkClicked() to take advantage of it. - Added an easier to use wxMenu::AppendSubMenu() - wxString <-> wxColour conversions in wxColour class (Francesco Montorsi). +- Fixed bug with ignoring blank lines in multiline wxGrid cell labels wxMSW: diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index 385a1cf310..81140534de 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -7606,6 +7606,12 @@ void wxGrid::DrawTextRectangle(wxDC& dc, { const wxString& line = lines[l]; + if ( line.empty() ) + { + *(textOrientation == wxHORIZONTAL ? &y : &x) += dc.GetCharHeight(); + continue; + } + long lineWidth, lineHeight; dc.GetTextExtent(line, &lineWidth, &lineHeight);