diff options
-rw-r--r-- | sc/source/ui/view/cellsh3.cxx | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx index 43abca74e734..5f4275fd8572 100644 --- a/sc/source/ui/view/cellsh3.cxx +++ b/sc/source/ui/view/cellsh3.cxx @@ -690,7 +690,9 @@ void ScCellShell::Execute( SfxRequest& rReq ) ScopedVclPtr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg( pTabViewShell->GetFrameWeld(), "RowHeightDialog", nCurHeight, ScGlobal::nStdRowHeight, - eMetric, 4, MAX_ROW_HEIGHT)); + eMetric, + nCurHeight == ScGlobal::nStdRowHeight ? 2 : 4, //use 4 digits for user-defined values + MAX_ROW_HEIGHT)); if ( pDlg->Execute() == RET_OK ) { @@ -727,7 +729,7 @@ void ScCellShell::Execute( SfxRequest& rReq ) ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); ScopedVclPtr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg( pTabViewShell->GetFrameWeld(), "OptimalRowHeightDialog", - ScGlobal::nLastRowHeightExtra, 0, eMetric, 4, MAX_EXTRA_HEIGHT)); + ScGlobal::nLastRowHeightExtra, 0, eMetric, 2, MAX_EXTRA_HEIGHT)); if ( pDlg->Execute() == RET_OK ) { tools::Long nVal = pDlg->GetInputValue(); @@ -788,7 +790,9 @@ void ScCellShell::Execute( SfxRequest& rReq ) ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); ScopedVclPtr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg( pTabViewShell->GetFrameWeld(), "ColWidthDialog", nCurHeight, - STD_COL_WIDTH, eMetric, 4, MAX_COL_WIDTH)); + STD_COL_WIDTH, eMetric, + nCurHeight == STD_COL_WIDTH ? 2 : 4, //use 4 digits for user-defined values + MAX_COL_WIDTH)); if ( pDlg->Execute() == RET_OK ) { tools::Long nVal = pDlg->GetInputValue(); @@ -824,7 +828,7 @@ void ScCellShell::Execute( SfxRequest& rReq ) ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); ScopedVclPtr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg( pTabViewShell->GetFrameWeld(), "OptimalColWidthDialog", - ScGlobal::nLastColWidthExtra, STD_EXTRA_WIDTH, eMetric, 4, MAX_EXTRA_WIDTH)); + ScGlobal::nLastColWidthExtra, STD_EXTRA_WIDTH, eMetric, 2, MAX_EXTRA_WIDTH)); if ( pDlg->Execute() == RET_OK ) { tools::Long nVal = pDlg->GetInputValue(); |