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

Mark Hung marklh9 at gmail.com
Mon Nov 20 12:25:45 UTC 2017


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

New commits:
commit 51b9042efea0984da96318812124836e292271d7
Author: Mark Hung <marklh9 at gmail.com>
Date:   Sat Nov 18 22:42:34 2017 +0800

    tdf#95656 vcl: correct offset for vkrn position
    
    For Bopomofo tone marks to attach to anchor points.
    
    Change-Id: I66373790cb80515f4ab0ca9c166f78634eb4081c
    Reviewed-on: https://gerrit.libreoffice.org/44922
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Mark Hung <marklh9 at gmail.com>

diff --git a/vcl/source/gdi/CommonSalLayout.cxx b/vcl/source/gdi/CommonSalLayout.cxx
index 08842283f908..2f110b138a8a 100644
--- a/vcl/source/gdi/CommonSalLayout.cxx
+++ b/vcl/source/gdi/CommonSalLayout.cxx
@@ -580,7 +580,6 @@ bool CommonSalLayout::LayoutText(ImplLayoutArgs& rArgs)
             int32_t nEndRunPos = std::min(pTextLayout->runs[k].nEnd, nBidiEndRunPos);
             hb_direction_t aDirection = bRightToLeft ? HB_DIRECTION_RTL : HB_DIRECTION_LTR;
             hb_script_t aScript = hb_icu_script_to_script(pTextLayout->runs[k].nCode);
-
             // For vertical text, further divide the runs based on character
             // orientation.
             if (rArgs.mnFlags & SalLayoutFlags::Vertical)
@@ -742,8 +741,8 @@ bool CommonSalLayout::LayoutText(ImplLayoutArgs& rArgs)
                             &pHbPositions[i].x_offset ,
                             &pHbPositions[i].y_offset );
                     nAdvance = -pHbPositions[i].y_advance;
-                    nXOffset =  pHbPositions[i].y_offset;
-                    nYOffset =  pHbPositions[i].x_offset;
+                    nXOffset = -pHbPositions[i].y_offset;
+                    nYOffset = -pHbPositions[i].x_offset;
                 }
                 else
                 {


More information about the Libreoffice-commits mailing list