diff options
author | Hannah Lyhne <hdlyhne1@gmail.com> | 2014-04-01 07:55:39 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2014-04-03 13:41:17 -0400 |
commit | 036b1fccbfb87a1aab36632843deb29e0a70630f (patch) | |
tree | 9940cf055a400cdb1b2e16298081d4e7ccbe3495 /sc | |
parent | 364c989e2e4f1f1897408882b2887a2bfb09a306 (diff) |
fdo#73588: fix default alignment in RTL mode.
Change-Id: Icb932ee51dbf32d8baf4382aa00e89a680f5a41d
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/view/output2.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx index 5d1ae1997649..18e3e8153e8d 100644 --- a/sc/source/ui/view/output2.cxx +++ b/sc/source/ui/view/output2.cxx @@ -1434,7 +1434,10 @@ static SvxCellHorJustify getAlignmentFromContext( SvxCellHorJustify eInHorJust, else if (nDirection == FRMDIR_ENVIRONMENT) { SAL_WARN_IF( !pDoc, "sc.ui", "getAlignmentFromContext - pDoc==NULL"); - eHorJustContext = (pDoc && pDoc->IsLayoutRTL(nTab)) ? SVX_HOR_JUSTIFY_RIGHT : SVX_HOR_JUSTIFY_LEFT; + // fdo#73588: The content of the cell must also + // begin with a RTL character to be right + // aligned; otherwise, it should be left aligned. + eHorJustContext = (pDoc && pDoc->IsLayoutRTL(nTab) && (beginsWithRTLCharacter( rText))) ? SVX_HOR_JUSTIFY_RIGHT : SVX_HOR_JUSTIFY_LEFT; } else eHorJustContext = SVX_HOR_JUSTIFY_RIGHT; |