tdf#132388: reimplement fix for tdf#142487
commita03b7d2a8d0f0fd7e710202bbeecf165f0fcd06a
authorMike Kaganski <mike.kaganski@collabora.com>
Sun, 30 Jan 2022 11:12:46 +0000 (30 14:12 +0300)
committerMike Kaganski <mike.kaganski@collabora.com>
Sun, 30 Jan 2022 14:19:39 +0000 (30 15:19 +0100)
treea7c9872b51a886336fa4e991e4ff654bd84e83ba
parent63e8c2ccd39263b24f644c3d0394044a2613eb88
tdf#132388: reimplement fix for tdf#142487

Each call to css::i18n::XTextSearch::SearchForward transliterates input string,
making performance of repeated calls unacceptable. So prepare the transliterated
strings once, and use the offset sequence to map search results to indices into
original string.

Change-Id: Ie08dd5a408aca9a950067db285a480b41a3f9a16
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129162
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
basic/source/runtime/methods.cxx