diff options
author | Tomcsik Bence <tomcsikbence@gmail.com> | 2012-02-14 18:25:47 +0100 |
---|---|---|
committer | Andras Timar <atimar@suse.com> | 2012-02-14 18:56:57 +0100 |
commit | 545a55895acfe15a454ca701eff7197eb8dbc3f3 (patch) | |
tree | bbe5a0a25a68d0850aa4b3f543913932a93776e9 /desktop | |
parent | 9b3372d8f0d59c8bf6789974d04733dff30bd131 (diff) |
fix layout of checkboxes on Extension Manager dialog fdo#45851
I changed the sizes and the positions of the checkboxes. So there won't be
truncated checkboxes in any languages.
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/deployment/gui/dp_gui_dialog2.cxx | 34 |
1 files changed, 25 insertions, 9 deletions
diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx index 416e5670c196..39606f10af96 100644 --- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx +++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx @@ -1244,16 +1244,32 @@ void ExtMgrDialog::Resize() // checkboxes + text "type of extensions" - Size aCBSize(m_aBundledCbx.GetSizePixel()); - - offsetX = 0.5*(aTotalSize.Width() - RSC_SP_DLG_INNERBORDER_LEFT - RSC_SP_DLG_INNERBORDER_RIGHT - 3*(aCBSize.Width() + RSC_SP_CTRL_GROUP_X) ); + long nWidth = m_aBundledCbx.GetCtrlTextWidth( m_aBundledCbx.GetText() ); + Size aBCBSize(m_aBundledCbx.GetSizePixel()); + aBCBSize.Width() = nWidth + 30; + aBCBSize.Height() += 3; + m_aBundledCbx.SetSizePixel( aBCBSize ); + + nWidth = m_aSharedCbx.GetCtrlTextWidth( m_aSharedCbx.GetText() ); + Size aSCBSize(m_aSharedCbx.GetSizePixel()); + aSCBSize.Width() = nWidth + 30; + aSCBSize.Height() += 3; + m_aSharedCbx.SetSizePixel( aSCBSize ); + + nWidth = m_aUserCbx.GetCtrlTextWidth( m_aUserCbx.GetText() ); + Size aUCBSize(m_aUserCbx.GetSizePixel()); + aUCBSize.Width() = nWidth + 30; + aUCBSize.Height() += 3; + m_aUserCbx.SetSizePixel( aUCBSize ); + + offsetX = 0.5*(aTotalSize.Width() - RSC_SP_DLG_INNERBORDER_LEFT - RSC_SP_DLG_INNERBORDER_RIGHT - 3*RSC_SP_CTRL_GROUP_X - aBCBSize.Width() - aSCBSize.Width() - aUCBSize.Width() ); aPos = Point(offsetX, aPos.Y() - RSC_CD_CHECKBOX_HEIGHT - 2*RSC_SP_DLG_INNERBORDER_BOTTOM); - m_aBundledCbx.SetPosSizePixel(aPos, aCBSize); - aPos.X() = aPos.X() + aCBSize.Width() + 2 * RSC_SP_CTRL_GROUP_X; - m_aSharedCbx.SetPosSizePixel(aPos, aCBSize); - aPos.X() = aPos.X() + aCBSize.Width() + 2 * RSC_SP_CTRL_GROUP_X; - m_aUserCbx.SetPosSizePixel(aPos, aCBSize); + m_aBundledCbx.SetPosPixel( aPos ); + aPos.X() += aBCBSize.Width() + 3 * RSC_SP_CTRL_GROUP_X; + m_aSharedCbx.SetPosPixel( aPos ); + aPos.X() += aSCBSize.Width() + 3 * RSC_SP_CTRL_GROUP_X; + m_aUserCbx.SetPosPixel( aPos ); Size aFTTypeOfExtSize(m_aTypeOfExtTxt.GetSizePixel()); aPos = Point(RSC_SP_DLG_INNERBORDER_LEFT , aPos.Y() - RSC_CD_FIXEDTEXT_HEIGHT - 2*RSC_SP_DLG_INNERBORDER_BOTTOM); @@ -1269,7 +1285,7 @@ void ExtMgrDialog::Resize() Size aSize( aTotalSize.Width() - RSC_SP_DLG_INNERBORDER_LEFT - RSC_SP_DLG_INNERBORDER_RIGHT, aTotalSize.Height() - aBtnSize.Height() - LINE_SIZE - aBtnSize.Height() - - aCBSize.Height() - aFTTypeOfExtSize.Height() + - aBCBSize.Height() - aFTTypeOfExtSize.Height() - RSC_SP_DLG_INNERBORDER_TOP - 5*RSC_SP_DLG_INNERBORDER_BOTTOM ); m_pExtensionBox->SetSizePixel(aSize ); |