summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorKhaled Hosny <khaled@libreoffice.org>2023-06-20 10:17:49 +0300
committerAndras Timar <andras.timar@collabora.com>2023-06-26 09:27:04 +0200
commitc59ed7701605effde73782db18da3293ea30c12d (patch)
tree4b1d813057946f8d2520562bdd8970c972f4be5d /vcl
parentf923efb8e3781f13b8814b3f9179e2442a20ca5e (diff)
tdf#107718: Fix script itemization of vertical text
Mixed script vertical text was not correctly splitting runs at script changes, resulting in Hangul text being mixed with Han text in the same run breaking the Hangul composition. Change-Id: I09c3f799bede6aa8a19684779d500504a9813af7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153313 Tested-by: Jenkins Reviewed-by: خالد حسني <khaled@libreoffice.org> (cherry picked from commit 1afc13b0b84353109827d78807836c01f030ab66) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153335 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/gdi/CommonSalLayout.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/gdi/CommonSalLayout.cxx b/vcl/source/gdi/CommonSalLayout.cxx
index 5cac0ebdb6b0..754b228f8ad3 100644
--- a/vcl/source/gdi/CommonSalLayout.cxx
+++ b/vcl/source/gdi/CommonSalLayout.cxx
@@ -391,7 +391,7 @@ bool GenericSalLayout::LayoutText(vcl::text::ImplLayoutArgs& rArgs, const SalLay
aDirection = bRightToLeft ? HB_DIRECTION_RTL : HB_DIRECTION_LTR;
}
- if (aSubRuns.empty() || aSubRuns.back().maDirection != aDirection)
+ if (aSubRuns.empty() || aSubRuns.back().maDirection != aDirection || aSubRuns.back().maScript != aScript)
aSubRuns.push_back({ nPrevIdx, nIdx, aScript, aDirection });
else
aSubRuns.back().mnEnd = nIdx;