[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - sc/source
Hannah Lyhne
hdlyhne1 at gmail.com
Thu Apr 10 21:04:42 PDT 2014
sc/source/ui/view/output2.cxx | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
New commits:
commit 4a2c3371f3ca1cc05732041c96cff9bf494bddb6
Author: Hannah Lyhne <hdlyhne1 at gmail.com>
Date: Tue Apr 1 07:55:39 2014 -0400
fdo#73588: fix default alignment in RTL mode.
(cherry picked from commit 036b1fccbfb87a1aab36632843deb29e0a70630f)
Change-Id: Icb932ee51dbf32d8baf4382aa00e89a680f5a41d
Signed-off-by: Kohei Yoshida <kohei.yoshida at collabora.com>
diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx
index 9c09b5c..544e737 100644
--- a/sc/source/ui/view/output2.cxx
+++ b/sc/source/ui/view/output2.cxx
@@ -1432,7 +1432,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;
More information about the Libreoffice-commits
mailing list