[Libreoffice-commits] core.git: vcl/source

Khaled Hosny khaledhosny at eglug.org
Sat Mar 18 06:05:33 UTC 2017


 vcl/source/gdi/CommonSalLayout.cxx |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 6c0525ff453464525cf6f5f2778e55b32de20e01
Author: Khaled Hosny <khaledhosny at eglug.org>
Date:   Sat Mar 18 08:00:04 2017 +0200

    Move the check to start, clearer this way
    
    Change-Id: I6c7626161d7f8ab8ee2a8a87eea470338861d80e

diff --git a/vcl/source/gdi/CommonSalLayout.cxx b/vcl/source/gdi/CommonSalLayout.cxx
index 7ef1fac1286f..07b82dae5302 100644
--- a/vcl/source/gdi/CommonSalLayout.cxx
+++ b/vcl/source/gdi/CommonSalLayout.cxx
@@ -307,15 +307,16 @@ namespace vcl {
 
     VerticalOrientation GetVerticalOrientation(sal_UCS4 cCh, const LanguageTag& rTag)
     {
+        // Override fullwidth colon and semi-colon orientation. Tu is preferred.
+        if ((cCh == 0xff1a || cCh == 0xff1b) && rTag.getLanguage() == "zh")
+            return VerticalOrientation::TransformedUpright;
+
         uint8_t nRet = 1;
 
         if (cCh < 0x10000)
         {
             nRet = sVerticalOrientationValues[sVerticalOrientationPages[0][cCh >> kVerticalOrientationCharBits]]
                                   [cCh & ((1 << kVerticalOrientationCharBits) - 1)];
-            // Override fullwidth colon and semi-colon orientation. Tu is preferred.
-            if ((cCh == 0xff1a || cCh == 0xff1b) && rTag.getLanguage() == "zh")
-                nRet = 2;
         }
         else if (cCh < (kVerticalOrientationMaxPlane + 1) * 0x10000)
         {


More information about the Libreoffice-commits mailing list