diff options
author | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-08-26 00:54:50 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-08-26 00:54:50 -0400 |
commit | ce3d5f9e8f02a722839ab6da4970bd54f6c846dc (patch) | |
tree | d5354827145a76494ef5030f88d0bd0d9d5b0012 | |
parent | 66e216778eb0da5765ced3017926da23b3eac031 (diff) |
Actually I can handle repeat horizontal alignment beforehand.
-rw-r--r-- | sc/source/ui/view/output2.cxx | 29 |
1 files changed, 8 insertions, 21 deletions
diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx index bc31fa8bdc20..10ef6f557d01 100644 --- a/sc/source/ui/view/output2.cxx +++ b/sc/source/ui/view/output2.cxx @@ -2940,18 +2940,12 @@ void ScOutputData::DrawEditStandard(DrawEditParam& rParam) void ScOutputData::DrawEditBottomTop(DrawEditParam& rParam) { + OSL_ASSERT(rParam.meHorJust != SVX_HOR_JUSTIFY_REPEAT); Size aRefOne = pRefDevice->PixelToLogic(Size(1,1)); bool bRepeat = (rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT && !rParam.mbBreak); bool bShrink = !rParam.mbBreak && !bRepeat && lcl_GetBoolValue(*rParam.mpPattern, ATTR_SHRINKTOFIT, rParam.mpCondSet); - if ( rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT ) - { - // ignore orientation/rotation if "repeat" is active - DrawEditStandard(rParam); - return; - } - SvxCellHorJustify eOutHorJust = ( rParam.meHorJust != SVX_HOR_JUSTIFY_STANDARD ) ? rParam.meHorJust : ( rParam.mbCellIsValue ? SVX_HOR_JUSTIFY_RIGHT : SVX_HOR_JUSTIFY_LEFT ); @@ -3316,18 +3310,12 @@ void ScOutputData::DrawEditBottomTop(DrawEditParam& rParam) void ScOutputData::DrawEditTopBottom(DrawEditParam& rParam) { + OSL_ASSERT(rParam.meHorJust != SVX_HOR_JUSTIFY_REPEAT); Size aRefOne = pRefDevice->PixelToLogic(Size(1,1)); bool bRepeat = (rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT && !rParam.mbBreak); bool bShrink = !rParam.mbBreak && !bRepeat && lcl_GetBoolValue(*rParam.mpPattern, ATTR_SHRINKTOFIT, rParam.mpCondSet); - if ( rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT ) - { - // ignore orientation/rotation if "repeat" is active - DrawEditStandard(rParam); - return; - } - SvxCellHorJustify eOutHorJust = ( rParam.meHorJust != SVX_HOR_JUSTIFY_STANDARD ) ? rParam.meHorJust : ( rParam.mbCellIsValue ? SVX_HOR_JUSTIFY_RIGHT : SVX_HOR_JUSTIFY_LEFT ); @@ -3687,18 +3675,12 @@ void ScOutputData::DrawEditTopBottom(DrawEditParam& rParam) void ScOutputData::DrawEditStacked(DrawEditParam& rParam) { + OSL_ASSERT(rParam.meHorJust != SVX_HOR_JUSTIFY_REPEAT); Size aRefOne = pRefDevice->PixelToLogic(Size(1,1)); bool bRepeat = (rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT && !rParam.mbBreak); bool bShrink = !rParam.mbBreak && !bRepeat && lcl_GetBoolValue(*rParam.mpPattern, ATTR_SHRINKTOFIT, rParam.mpCondSet); - if ( rParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT ) - { - // ignore orientation/rotation if "repeat" is active - DrawEditStandard(rParam); - return; - } - rParam.mbAsianVertical = lcl_GetBoolValue(*rParam.mpPattern, ATTR_VERTICAL_ASIAN, rParam.mpCondSet); @@ -4606,6 +4588,11 @@ void ScOutputData::DrawEdit(sal_Bool bPixelToLogic) aParam.mpOldPattern = pOldPattern; aParam.mpOldCondSet = pOldCondSet; aParam.mpThisRowInfo = pThisRowInfo; + if (aParam.meHorJust == SVX_HOR_JUSTIFY_REPEAT) + { + // ignore orientation/rotation if "repeat" is active + aParam.meOrient = SVX_ORIENTATION_STANDARD; + } switch (aParam.meOrient) { case SVX_ORIENTATION_BOTTOMTOP: |