sw/source/core/docnode/ndtbl1.cxx | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-)
New commits: commit bb681a1cbb5a8382a7d521d901bc101496085519 Author: Faisal M. Al-Otaibi <fmalota...@kacst.edu.sa> Date: Mon Apr 1 10:31:00 2013 +0300 fdo#62470 fix the table format dialog reading this will fix the wrong reading in table format borders dialog. Change-Id: Ie8061ec4073fe9fd779a739ed717348d37319fe4 Change-Id: I624cf7c162d3983fe4625e8e2e6fef4fc556eed0 Reviewed-on: https://gerrit.libreoffice.org/3134 Reviewed-by: Ahmad Harthi <aalhar...@kacst.edu.sa> Tested-by: Ahmad Harthi <aalhar...@kacst.edu.sa> diff --git a/sw/source/core/docnode/ndtbl1.cxx b/sw/source/core/docnode/ndtbl1.cxx index e38d9aa6..9fa5d7e 100644 --- a/sw/source/core/docnode/ndtbl1.cxx +++ b/sw/source/core/docnode/ndtbl1.cxx @@ -934,7 +934,8 @@ void SwDoc::GetTabBorders( const SwCursor& rCursor, SfxItemSet& rSet ) const bRightSet = sal_False, bHoriSet = sal_False, bVertSet = sal_False, - bDistanceSet = sal_False; + bDistanceSet = sal_False, + bRTLTab = sal_False; aSetBoxInfo.ResetFlags(); @@ -954,7 +955,7 @@ void SwDoc::GetTabBorders( const SwCursor& rCursor, SfxItemSet& rSet ) const { SwCellFrm *pCell = aCellArr[j]; const sal_Bool bVert = pTab->IsVertical(); - const sal_Bool bRTL = pTab->IsRightToLeft(); + const sal_Bool bRTL = bRTLTab = pTab->IsRightToLeft(); sal_Bool bTopOver, bLeftOver, bRightOver, bBottomOver; if ( bVert ) { @@ -1115,6 +1116,22 @@ void SwDoc::GetTabBorders( const SwCursor& rCursor, SfxItemSet& rSet ) const } } } + + // fdo#62470 fix the reading for table format. + if ( bRTLTab ) + { + SvxBoxItem aTempBox ((const SvxBoxItem &) rSet.Get(RES_BOX )); + SvxBoxInfoItem aTempBoxInfo((const SvxBoxInfoItem&) rSet.Get(SID_ATTR_BORDER_INNER)); + + aTempBox.SetLine( aSetBox.GetRight(), BOX_LINE_RIGHT); + aSetBox.SetLine( aSetBox.GetLeft(), BOX_LINE_RIGHT); + aSetBox.SetLine( aTempBox.GetRight(), BOX_LINE_LEFT); + + aTempBoxInfo.SetValid( VALID_LEFT, aSetBoxInfo.IsValid(VALID_LEFT) ); + aSetBoxInfo.SetValid( VALID_LEFT, aSetBoxInfo.IsValid(VALID_RIGHT) ); + aSetBoxInfo.SetValid( VALID_RIGHT, aTempBoxInfo.IsValid(VALID_LEFT) ); + } + rSet.Put( aSetBox ); rSet.Put( aSetBoxInfo ); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits