From 3a5c9d1005e34bf0ea80cfe266953193b15feb61 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 14 Mar 2007 00:29:43 +0000 Subject: [PATCH] don't add extra GetCharHeight() pixels to the top border if our label is empty (patch 1581459) [backport from HEAD] git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@44797 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- docs/changes.txt | 7 +++++++ src/mac/carbon/statbox.cpp | 5 ++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/changes.txt b/docs/changes.txt index 900532ef5b..9e3d090e2c 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -88,6 +88,13 @@ Major new features in 2.8 release wxSearchCtrl, wxAboutBox, wxTreebook, tar streams. +2.8.3 +----- + +wxMac + +- Corrected top border size for wxStaticBox with empty label (nusi) + 2.8.2 ----- diff --git a/src/mac/carbon/statbox.cpp b/src/mac/carbon/statbox.cpp index cb3b47de90..53dfd54635 100644 --- a/src/mac/carbon/statbox.cpp +++ b/src/mac/carbon/statbox.cpp @@ -68,7 +68,10 @@ void wxStaticBox::GetBordersForSizer(int *borderTop, int *borderOther) const } } - *borderTop = extraTop + GetCharHeight(); + *borderTop = extraTop; + if ( !m_label.empty() ) + *borderTop += GetCharHeight(); + *borderOther = other; }