summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-11-02 20:30:14 +0100
committerEike Rathke <erack@redhat.com>2013-11-02 17:12:12 -0500
commitde67c6d6159c0801b0959d77c2c8a8b7fb148b03 (patch)
treeed6cbd756a399253374312cf07af7963d932ce23
parentc5112b0ab7c97a092981fe0d1a6c8bf37931b53e (diff)
no default LTR mode does not mean RTL, fdo#68097
Change-Id: Ice4957077e7eda5f7bb93042d6e2ba745935ef8b (cherry picked from commit 045e037b7acde9d8e63fbb977c28b167e8815278) Reviewed-on: https://gerrit.libreoffice.org/6527 Tested-by: Eike Rathke <erack@redhat.com> Reviewed-by: Eike Rathke <erack@redhat.com>
-rw-r--r--sc/source/ui/view/output2.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx
index 8c6439355ddb..cf7be64ba394 100644
--- a/sc/source/ui/view/output2.cxx
+++ b/sc/source/ui/view/output2.cxx
@@ -1666,8 +1666,13 @@ void ScOutputData::DrawStrings( sal_Bool bPixelToLogic )
{
const SfxPoolItem* pItem = mpDoc->GetAttr( nCellX, nCellY, nTab, ATTR_WRITINGDIR );
const SvxFrameDirectionItem* pCurrentWritingMode = (const SvxFrameDirectionItem*) pItem;
- if (pCurrentWritingMode->GetValue() == FRMDIR_HORI_LEFT_TOP)
+ sal_uInt16 aDirection = pCurrentWritingMode->GetValue();
+ if ( aDirection == FRMDIR_HORI_LEFT_TOP || aDirection == FRMDIR_VERT_TOP_LEFT )
eOutHorJust = SVX_HOR_JUSTIFY_LEFT;
+ else if ( aDirection == FRMDIR_ENVIRONMENT )
+ {
+ eOutHorJust = mpDoc->IsLayoutRTL(nTab) ? SVX_HOR_JUSTIFY_RIGHT : SVX_HOR_JUSTIFY_LEFT;
+ }
else
eOutHorJust = SVX_HOR_JUSTIFY_RIGHT;
}