summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorAriel Constenla-Haile <arielch@apache.org>2013-02-25 14:09:43 +0000
committerAriel Constenla-Haile <arielch@apache.org>2013-02-25 14:09:43 +0000
commit3c8d9a3e00bb62a98d375898ff30b8dfcc670ca9 (patch)
tree4a20e371526a84fb78b7a3bc9f15d8d88f0bf08f /sc
parentf94bdb4d6184ece5b2cafebd2ede207ef331cf16 (diff)
i117782 - Re-size controls according to the optimal size
Notes
Notes: prefer: 28ca8eeee8898c5cd3730ebfcbbf303b68d25150
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/optdlg/tpcalc.cxx11
-rw-r--r--sc/source/ui/src/optdlg.src3
2 files changed, 13 insertions, 1 deletions
diff --git a/sc/source/ui/optdlg/tpcalc.cxx b/sc/source/ui/optdlg/tpcalc.cxx
index eab90187ab42..608b6f639683 100644
--- a/sc/source/ui/optdlg/tpcalc.cxx
+++ b/sc/source/ui/optdlg/tpcalc.cxx
@@ -112,6 +112,17 @@ __EXPORT ScTpCalcOptions::~ScTpCalcOptions()
void ScTpCalcOptions::Init()
{
+ const Size a6Size = aFtPrec.LogicToPixel( Size( 6, 6 ), MAP_APPFONT );
+ const Size aMin = aFtPrec.CalcMinimumSize();
+ const Point aPos = aFtPrec.GetPosPixel();
+ const long nNewX = aPos.X() + aFtPrec.GetSizePixel().Width() - aMin.Width();
+
+ aFtPrec.SetPosPixel( Point( nNewX, aPos.Y() ) );
+ aFtPrec.SetSizePixel( aMin );
+ aBtnGeneralPrec.SetSizePixel( Size(
+ nNewX - a6Size.Width() - aBtnGeneralPrec.GetPosPixel().X(),
+ aBtnGeneralPrec.GetSizePixel().Height() ) );
+
aBtnIterate .SetClickHdl( LINK( this, ScTpCalcOptions, CheckClickHdl ) );
aBtnGeneralPrec.SetClickHdl( LINK(this, ScTpCalcOptions, CheckClickHdl) );
aBtnDateStd .SetClickHdl( LINK( this, ScTpCalcOptions, RadioClickHdl ) );
diff --git a/sc/source/ui/src/optdlg.src b/sc/source/ui/src/optdlg.src
index b8c5332979c5..782396b5e8e1 100644
--- a/sc/source/ui/src/optdlg.src
+++ b/sc/source/ui/src/optdlg.src
@@ -160,8 +160,9 @@ TabPage RID_SCPAGE_CALC
{
HelpID = "sc:CheckBox:RID_SCPAGE_CALC:BTN_GENERAL_PREC";
Pos = MAP_APPFONT ( 12 , 147 ) ;
- Size = MAP_APPFONT ( 200 , 10 ) ;
+ Size = MAP_APPFONT ( 148 , 26 ) ;
Text [ en-US ] = "Limit decimals for general number format" ;
+ WordBreak = TRUE ;
};
FixedText FT_PREC
{