clip the text in report mode to prevent it from overflowing into the next column (patch 1898914)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52151 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1569,6 +1569,9 @@ void wxListLineData::DrawInReportMode( wxDC *dc,
|
|||||||
int xOld = x;
|
int xOld = x;
|
||||||
x += width;
|
x += width;
|
||||||
|
|
||||||
|
const int wText = width - 8;
|
||||||
|
wxDCClipper clipper(*dc, xOld, rect.y, wText, rect.height);
|
||||||
|
|
||||||
if ( item->HasImage() )
|
if ( item->HasImage() )
|
||||||
{
|
{
|
||||||
int ix, iy;
|
int ix, iy;
|
||||||
@@ -1582,7 +1585,7 @@ void wxListLineData::DrawInReportMode( wxDC *dc,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( item->HasText() )
|
if ( item->HasText() )
|
||||||
DrawTextFormatted(dc, item->GetText(), col, xOld, yMid, width - 8);
|
DrawTextFormatted(dc, item->GetText(), col, xOld, yMid, wText);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user