fixed wxStatusBar size calculations so that the text is not clipped

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41503 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2006-09-29 11:45:26 +00:00
parent ab00f409f4
commit 283c797c5c
4 changed files with 49 additions and 12 deletions

View File

@@ -86,7 +86,8 @@ wxRect wxStatusBarUniv::GetTotalFieldRect(wxCoord *borderBetweenFields)
// no, don't do this - the borders are meant to be inside this rect
// wxSize sizeBorders =
m_renderer->GetStatusBarBorders(borderBetweenFields);
if ( borderBetweenFields )
*borderBetweenFields = m_renderer->GetStatusBarBorderBetweenFields();
//rect.Deflate(sizeBorders.x, sizeBorders.y);
// recalc the field widths if needed
@@ -311,12 +312,14 @@ void wxStatusBarUniv::SetMinHeight(int WXUNUSED(height))
int wxStatusBarUniv::GetBorderX() const
{
return m_renderer->GetStatusBarBorders(NULL).x;
return m_renderer->GetStatusBarBorders().x +
m_renderer->GetStatusBarFieldMargins().x;
}
int wxStatusBarUniv::GetBorderY() const
{
return m_renderer->GetStatusBarBorders(NULL).y;
return m_renderer->GetStatusBarBorders().y +
m_renderer->GetStatusBarFieldMargins().y;
}
#endif // wxUSE_STATUSBAR