From cf425acfd4a5ff7c660523601964d45cbad74b53 Mon Sep 17 00:00:00 2001
From: Khaled Hosny <khaledhosny@eglug.org>
Date: Fri, 26 Aug 2016 15:19:26 +0200
Subject: tdf#56403: Text is right aligned in RTL locales

Draw/Impress is setting writing mode to RTL (which in turn sets text
alignment to right) if the current locale is RTL one. This does not make
sense at all since it means document prepared on a LTR locale and
contains LTR text will appear right aligned on RTL locales.

It would have slightly more sense if SetDefaultWritingMode() actually
just set a default (for e.g. new documents), but that is not the case
here as it affects all documents.

This was introduced in 2c32696a04bc195c8ce61a0df6dcafb8c0c49fe0 with a
branch merge and no further explanation.

Change-Id: Idee0f58e153498a6676a22242d2edd5054b908c6
Reviewed-on: https://gerrit.libreoffice.org/28411
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
---
 sd/source/core/drawdoc.cxx | 5 -----
 1 file changed, 5 deletions(-)

(limited to 'sd')

diff --git a/sd/source/core/drawdoc.cxx b/sd/source/core/drawdoc.cxx
index bdf3395cd677..c448609864e9 100644
--- a/sd/source/core/drawdoc.cxx
+++ b/sd/source/core/drawdoc.cxx
@@ -243,11 +243,6 @@ SdDrawDocument::SdDrawDocument(DocumentType eType, SfxObjectShell* pDrDocSh)
 
     // If the current application language is a language that uses right-to-left text...
     LanguageType eRealCTLLanguage = Application::GetSettings().GetLanguageTag().getLanguageType();
-    if( MsLangId::isRightToLeft( eRealCTLLanguage ) )
-    {
-        // ... then we have to set this as a default
-        SetDefaultWritingMode( css::text::WritingMode_RL_TB );
-    }
 
     // for korean and japanese languages we have a different default for apply spacing between asian, latin and ctl text
     if (MsLangId::isKorean(eRealCTLLanguage) || (LANGUAGE_JAPANESE == eRealCTLLanguage))
-- 
cgit