- Extend the icu patch with more patches wrt bsc#1091772
* libreoffice-icu61.patch OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice?expand=0&rev=655
This commit is contained in:
parent
003bf404af
commit
a8a17081e2
@ -1,3 +1,75 @@
|
||||
From ad3b7c27cdc957a8a38876c040e86a81c3cf7003 Mon Sep 17 00:00:00 2001
|
||||
From: Eike Rathke <erack@redhat.com>
|
||||
Date: Mon, 18 Dec 2017 20:33:03 +0100
|
||||
Subject: Explicitly qualify ICU types with icu:: namespace
|
||||
|
||||
It will be required by ICU 61 anyway, see
|
||||
https://ssl.icu-project.org/repos/icu/trunk/icu4c/readme.html#RecBuild
|
||||
|
||||
Change-Id: Ia051e8e2aa64b0e32a7f16a2afebaef0e4ebf531
|
||||
Reviewed-on: https://gerrit.libreoffice.org/46739
|
||||
Reviewed-by: Eike Rathke <erack@redhat.com>
|
||||
Tested-by: Eike Rathke <erack@redhat.com>
|
||||
---
|
||||
i18nutil/source/utility/unicode.cxx | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/i18nutil/source/utility/unicode.cxx b/i18nutil/source/utility/unicode.cxx
|
||||
index 96c0194..f225b3a 100644
|
||||
--- a/i18nutil/source/utility/unicode.cxx
|
||||
+++ b/i18nutil/source/utility/unicode.cxx
|
||||
@@ -750,15 +750,15 @@ OUString unicode::formatPercent(double dNumber,
|
||||
|
||||
icu::Locale aLocale = LanguageTagIcu::getIcuLocale(aLangTag);
|
||||
|
||||
- std::unique_ptr<NumberFormat> xF(
|
||||
- NumberFormat::createPercentInstance(aLocale, errorCode));
|
||||
+ std::unique_ptr<icu::NumberFormat> xF(
|
||||
+ icu::NumberFormat::createPercentInstance(aLocale, errorCode));
|
||||
if(U_FAILURE(errorCode))
|
||||
{
|
||||
- SAL_WARN("i18n", "NumberFormat::createPercentInstance failed");
|
||||
+ SAL_WARN("i18n", "icu::NumberFormat::createPercentInstance failed");
|
||||
return OUString::number(dNumber) + "%";
|
||||
}
|
||||
|
||||
- UnicodeString output;
|
||||
+ icu::UnicodeString output;
|
||||
xF->format(dNumber/100, output);
|
||||
OUString aRet(reinterpret_cast<const sal_Unicode *>(output.getBuffer()),
|
||||
output.length());
|
||||
--
|
||||
cgit v1.1
|
||||
|
||||
From f240332f8e965ea17b70b0ccaa9990ce0a53cfc6 Mon Sep 17 00:00:00 2001
|
||||
From: Eike Rathke <erack@redhat.com>
|
||||
Date: Tue, 19 Dec 2017 15:22:09 +0100
|
||||
Subject: vcl: explicitly qualify ICU types with icu:: namespace
|
||||
|
||||
It will be required by ICU 61 anyway, see
|
||||
https://ssl.icu-project.org/repos/icu/trunk/icu4c/readme.html#RecBuild
|
||||
|
||||
Change-Id: Iecb30b903e9a67252147a8cc78c641621d763755
|
||||
---
|
||||
vcl/inc/scrptrun.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/vcl/inc/scrptrun.h b/vcl/inc/scrptrun.h
|
||||
index cbe151d..46a5c08 100644
|
||||
--- a/vcl/inc/scrptrun.h
|
||||
+++ b/vcl/inc/scrptrun.h
|
||||
@@ -58,7 +58,7 @@ struct ParenStackEntry
|
||||
}
|
||||
};
|
||||
|
||||
-class ScriptRun : public UObject {
|
||||
+class ScriptRun : public icu::UObject {
|
||||
public:
|
||||
|
||||
ScriptRun(const UChar chars[], int32_t length);
|
||||
--
|
||||
cgit v1.1
|
||||
|
||||
From f7961456d81c3ee6ee4c13eac9ef7add6c7ea6b5 Mon Sep 17 00:00:00 2001
|
||||
From: Eike Rathke <erack@redhat.com>
|
||||
Date: Mon, 18 Dec 2017 20:28:07 +0100
|
||||
@ -11,12 +83,133 @@ Reviewed-on: https://gerrit.libreoffice.org/46738
|
||||
Reviewed-by: Eike Rathke <erack@redhat.com>
|
||||
Tested-by: Eike Rathke <erack@redhat.com>
|
||||
---
|
||||
i18npool/source/collator/collator_unicode.cxx | 16 ++++++++--------
|
||||
i18npool/inc/collator_unicode.hxx | 2 +-
|
||||
.../source/breakiterator/breakiterator_unicode.cxx | 26 +++++++++++-----------
|
||||
i18npool/source/collator/collator_unicode.cxx | 16 ++++++-------
|
||||
i18npool/source/collator/gencoll_rule.cxx | 2 +-
|
||||
2 files changed, 9 insertions(+), 9 deletions(-)
|
||||
i18npool/source/ordinalsuffix/ordinalsuffix.cxx | 2 +-
|
||||
.../transliteration/ignoreDiacritics_CTL.cxx | 6 ++---
|
||||
6 files changed, 27 insertions(+), 27 deletions(-)
|
||||
|
||||
(limited to 'i18npool/source/collator')
|
||||
diff --git a/i18npool/inc/collator_unicode.hxx b/i18npool/inc/collator_unicode.hxx
|
||||
index 69d3177..d943bc9 100644
|
||||
--- a/i18npool/inc/collator_unicode.hxx
|
||||
+++ b/i18npool/inc/collator_unicode.hxx
|
||||
@@ -63,7 +63,7 @@ public:
|
||||
|
||||
private:
|
||||
const sal_Char *implementationName;
|
||||
- RuleBasedCollator *uca_base, *collator;
|
||||
+ icu::RuleBasedCollator *uca_base, *collator;
|
||||
#ifndef DISABLE_DYNLOADING
|
||||
oslModule hModule;
|
||||
#endif
|
||||
diff --git a/i18npool/source/breakiterator/breakiterator_unicode.cxx b/i18npool/source/breakiterator/breakiterator_unicode.cxx
|
||||
index a81a80e..02da856 100644
|
||||
--- a/i18npool/source/breakiterator/breakiterator_unicode.cxx
|
||||
+++ b/i18npool/source/breakiterator/breakiterator_unicode.cxx
|
||||
@@ -56,14 +56,14 @@ BreakIterator_Unicode::~BreakIterator_Unicode()
|
||||
}
|
||||
|
||||
/*
|
||||
- Wrapper class to provide public access to the RuleBasedBreakIterator's
|
||||
+ Wrapper class to provide public access to the icu::RuleBasedBreakIterator's
|
||||
setbreakType method.
|
||||
*/
|
||||
-class OOoRuleBasedBreakIterator : public RuleBasedBreakIterator
|
||||
+class OOoRuleBasedBreakIterator : public icu::RuleBasedBreakIterator
|
||||
{
|
||||
public:
|
||||
#if (U_ICU_VERSION_MAJOR_NUM < 58)
|
||||
- // RuleBasedBreakIterator::setBreakType() is private as of ICU 58.
|
||||
+ // icu::RuleBasedBreakIterator::setBreakType() is private as of ICU 58.
|
||||
void publicSetBreakType(int32_t type)
|
||||
{
|
||||
setBreakType(type);
|
||||
@@ -71,7 +71,7 @@ class OOoRuleBasedBreakIterator : public RuleBasedBreakIterator
|
||||
#endif
|
||||
OOoRuleBasedBreakIterator(UDataMemory* image,
|
||||
UErrorCode &status)
|
||||
- : RuleBasedBreakIterator(image, status)
|
||||
+ : icu::RuleBasedBreakIterator(image, status)
|
||||
{ };
|
||||
|
||||
};
|
||||
@@ -334,7 +334,7 @@ sal_Int32 SAL_CALL BreakIterator_Unicode::nextCharacters( const OUString& Text,
|
||||
icu::BreakIterator* pBI = character.mpValue->mpBreakIterator.get();
|
||||
for (nDone = 0; nDone < nCount; nDone++) {
|
||||
nStartPos = pBI->following(nStartPos);
|
||||
- if (nStartPos == BreakIterator::DONE)
|
||||
+ if (nStartPos == icu::BreakIterator::DONE)
|
||||
return Text.getLength();
|
||||
}
|
||||
} else { // for CHARACTER mode
|
||||
@@ -353,7 +353,7 @@ sal_Int32 SAL_CALL BreakIterator_Unicode::previousCharacters( const OUString& Te
|
||||
icu::BreakIterator* pBI = character.mpValue->mpBreakIterator.get();
|
||||
for (nDone = 0; nDone < nCount; nDone++) {
|
||||
nStartPos = pBI->preceding(nStartPos);
|
||||
- if (nStartPos == BreakIterator::DONE)
|
||||
+ if (nStartPos == icu::BreakIterator::DONE)
|
||||
return 0;
|
||||
}
|
||||
} else { // for BS to delete one char and CHARACTER mode.
|
||||
@@ -371,7 +371,7 @@ Boundary SAL_CALL BreakIterator_Unicode::nextWord( const OUString& Text, sal_Int
|
||||
|
||||
Boundary rv;
|
||||
rv.startPos = icuBI->mpValue->mpBreakIterator->following(nStartPos);
|
||||
- if( rv.startPos >= Text.getLength() || rv.startPos == BreakIterator::DONE )
|
||||
+ if( rv.startPos >= Text.getLength() || rv.startPos == icu::BreakIterator::DONE )
|
||||
rv.endPos = result.startPos;
|
||||
else {
|
||||
if ( (rWordType == WordType::ANYWORD_IGNOREWHITESPACES ||
|
||||
@@ -380,7 +380,7 @@ Boundary SAL_CALL BreakIterator_Unicode::nextWord( const OUString& Text, sal_Int
|
||||
rv.startPos = icuBI->mpValue->mpBreakIterator->following(rv.startPos);
|
||||
|
||||
rv.endPos = icuBI->mpValue->mpBreakIterator->following(rv.startPos);
|
||||
- if(rv.endPos == BreakIterator::DONE)
|
||||
+ if(rv.endPos == icu::BreakIterator::DONE)
|
||||
rv.endPos = rv.startPos;
|
||||
}
|
||||
return rv;
|
||||
@@ -394,7 +394,7 @@ Boundary SAL_CALL BreakIterator_Unicode::previousWord(const OUString& Text, sal_
|
||||
|
||||
Boundary rv;
|
||||
rv.startPos = icuBI->mpValue->mpBreakIterator->preceding(nStartPos);
|
||||
- if( rv.startPos < 0 || rv.startPos == BreakIterator::DONE)
|
||||
+ if( rv.startPos < 0 || rv.startPos == icu::BreakIterator::DONE)
|
||||
rv.endPos = rv.startPos;
|
||||
else {
|
||||
if ( (rWordType == WordType::ANYWORD_IGNOREWHITESPACES ||
|
||||
@@ -403,7 +403,7 @@ Boundary SAL_CALL BreakIterator_Unicode::previousWord(const OUString& Text, sal_
|
||||
rv.startPos = icuBI->mpValue->mpBreakIterator->preceding(rv.startPos);
|
||||
|
||||
rv.endPos = icuBI->mpValue->mpBreakIterator->following(rv.startPos);
|
||||
- if(rv.endPos == BreakIterator::DONE)
|
||||
+ if(rv.endPos == icu::BreakIterator::DONE)
|
||||
rv.endPos = rv.startPos;
|
||||
}
|
||||
return rv;
|
||||
@@ -435,9 +435,9 @@ Boundary SAL_CALL BreakIterator_Unicode::getWordBoundary( const OUString& Text,
|
||||
rv.endPos = icuBI->mpValue->mpBreakIterator->following(nPos);
|
||||
}
|
||||
}
|
||||
- if (rv.startPos == BreakIterator::DONE)
|
||||
+ if (rv.startPos == icu::BreakIterator::DONE)
|
||||
rv.startPos = rv.endPos;
|
||||
- else if (rv.endPos == BreakIterator::DONE)
|
||||
+ else if (rv.endPos == icu::BreakIterator::DONE)
|
||||
rv.endPos = rv.startPos;
|
||||
|
||||
return rv;
|
||||
@@ -502,7 +502,7 @@ LineBreakResults SAL_CALL BreakIterator_Unicode::getLineBreak(
|
||||
lbr.breakIndex = nStartPos;
|
||||
lbr.breakType = BreakType::WORDBOUNDARY;
|
||||
} else if (hOptions.rHyphenator.is()) { //Hyphenation break
|
||||
- sal_Int32 boundary_with_punctuation = (pLineBI->next() != BreakIterator::DONE) ? pLineBI->current() : 0;
|
||||
+ sal_Int32 boundary_with_punctuation = (pLineBI->next() != icu::BreakIterator::DONE) ? pLineBI->current() : 0;
|
||||
pLineBI->preceding(nStartPos + 1); // reset to check correct hyphenation of "word-word"
|
||||
|
||||
sal_Int32 nStartPosWordEnd = nStartPos;
|
||||
diff --git a/i18npool/source/collator/collator_unicode.cxx b/i18npool/source/collator/collator_unicode.cxx
|
||||
index 71bc4ed..37dc7ee 100644
|
||||
--- a/i18npool/source/collator/collator_unicode.cxx
|
||||
@ -88,6 +281,114 @@ index 7d795b5..3048d12 100644
|
||||
|
||||
if (U_SUCCESS(status)) {
|
||||
std::vector<uint8_t> data;
|
||||
diff --git a/i18npool/source/ordinalsuffix/ordinalsuffix.cxx b/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
|
||||
index 1a63dcb..b9efd51 100644
|
||||
--- a/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
|
||||
+++ b/i18npool/source/ordinalsuffix/ordinalsuffix.cxx
|
||||
@@ -79,7 +79,7 @@ uno::Sequence< OUString > SAL_CALL OrdinalSuffixService::getOrdinalSuffix( sal_I
|
||||
if (!U_SUCCESS(nCode))
|
||||
return retValue;
|
||||
|
||||
- std::unique_ptr<NumberFormat> xNumberFormat(icu::NumberFormat::createInstance(aIcuLocale, nCode));
|
||||
+ std::unique_ptr<icu::NumberFormat> xNumberFormat(icu::NumberFormat::createInstance(aIcuLocale, nCode));
|
||||
if (!U_SUCCESS(nCode))
|
||||
return retValue;
|
||||
|
||||
diff --git a/i18npool/source/transliteration/ignoreDiacritics_CTL.cxx b/i18npool/source/transliteration/ignoreDiacritics_CTL.cxx
|
||||
index 0ddfe64..2b5ca1e 100644
|
||||
--- a/i18npool/source/transliteration/ignoreDiacritics_CTL.cxx
|
||||
+++ b/i18npool/source/transliteration/ignoreDiacritics_CTL.cxx
|
||||
@@ -35,7 +35,7 @@ ignoreDiacritics_CTL::transliterateChar2Char(sal_Unicode nInChar)
|
||||
if (!m_transliterator)
|
||||
throw css::uno::RuntimeException();
|
||||
|
||||
- UnicodeString aChar(nInChar);
|
||||
+ icu::UnicodeString aChar(nInChar);
|
||||
m_transliterator->transliterate(aChar);
|
||||
|
||||
if (aChar.isEmpty())
|
||||
@@ -68,7 +68,7 @@ ignoreDiacritics_CTL::folding(const OUString& rInStr, sal_Int32 nStartPos,
|
||||
{
|
||||
sal_Int32 nIndex = nPosition;
|
||||
UChar32 nChar = rInStr.iterateCodePoints(&nIndex);
|
||||
- UnicodeString aUStr(nChar);
|
||||
+ icu::UnicodeString aUStr(nChar);
|
||||
m_transliterator->transliterate(aUStr);
|
||||
|
||||
if (nOffset + aUStr.length() > rOffset.getLength())
|
||||
@@ -87,7 +87,7 @@ ignoreDiacritics_CTL::folding(const OUString& rInStr, sal_Int32 nStartPos,
|
||||
}
|
||||
else
|
||||
{
|
||||
- UnicodeString aUStr(reinterpret_cast<const UChar*>(rInStr.getStr()) + nStartPos, nCount);
|
||||
+ icu::UnicodeString aUStr(reinterpret_cast<const UChar*>(rInStr.getStr()) + nStartPos, nCount);
|
||||
m_transliterator->transliterate(aUStr);
|
||||
return OUString(reinterpret_cast<const sal_Unicode*>(aUStr.getBuffer()), aUStr.length());
|
||||
}
|
||||
--
|
||||
cgit v1.1
|
||||
|
||||
From 7c46e0086802c22f5a5040d9161d4d2b3b2a3aff Mon Sep 17 00:00:00 2001
|
||||
From: Eike Rathke <erack@redhat.com>
|
||||
Date: Mon, 18 Dec 2017 20:38:59 +0100
|
||||
Subject: Explicitly qualify ICU types with icu:: namespace
|
||||
|
||||
It will be required by ICU 61 anyway, see
|
||||
https://ssl.icu-project.org/repos/icu/trunk/icu4c/readme.html#RecBuild
|
||||
|
||||
Change-Id: If7f1330550981fd28eb7eea6329f21e116291cca
|
||||
Reviewed-on: https://gerrit.libreoffice.org/46740
|
||||
Reviewed-by: Eike Rathke <erack@redhat.com>
|
||||
Tested-by: Eike Rathke <erack@redhat.com>
|
||||
---
|
||||
lotuswordpro/source/filter/localtime.cxx | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lotuswordpro/source/filter/localtime.cxx b/lotuswordpro/source/filter/localtime.cxx
|
||||
index 47d2024..3805c5d 100644
|
||||
--- a/lotuswordpro/source/filter/localtime.cxx
|
||||
+++ b/lotuswordpro/source/filter/localtime.cxx
|
||||
@@ -174,7 +174,7 @@ bool LtgLocalTime(long rtime,LtTm& rtm)
|
||||
|
||||
if ((rtime > 3 * DAY_SEC)&&(rtime < LONG_MAX - 3 * DAY_SEC))
|
||||
{
|
||||
- TimeZone* pLocalZone = TimeZone::createDefault();
|
||||
+ icu::TimeZone* pLocalZone = icu::TimeZone::createDefault();
|
||||
long offset = (pLocalZone->getRawOffset())/1000;
|
||||
delete pLocalZone;
|
||||
long ltime = rtime + offset;
|
||||
--
|
||||
cgit v1.1
|
||||
|
||||
From 8960ecc689ce41cfaa40b65d75830d7491b06463 Mon Sep 17 00:00:00 2001
|
||||
From: Eike Rathke <erack@redhat.com>
|
||||
Date: Mon, 18 Dec 2017 20:41:30 +0100
|
||||
Subject: Explicitly qualify ICU types with icu:: namespace
|
||||
|
||||
It will be required by ICU 61 anyway, see
|
||||
https://ssl.icu-project.org/repos/icu/trunk/icu4c/readme.html#RecBuild
|
||||
|
||||
Change-Id: Ib7accd75a6e35932048d779cf7bf0a5a33f8ed0d
|
||||
Reviewed-on: https://gerrit.libreoffice.org/46741
|
||||
Reviewed-by: Eike Rathke <erack@redhat.com>
|
||||
Tested-by: Eike Rathke <erack@redhat.com>
|
||||
---
|
||||
opencl/source/openclconfig.cxx | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/opencl/source/openclconfig.cxx b/opencl/source/openclconfig.cxx
|
||||
index b81ffed..0ec2347 100644
|
||||
--- a/opencl/source/openclconfig.cxx
|
||||
+++ b/opencl/source/openclconfig.cxx
|
||||
@@ -119,7 +119,7 @@ bool match(const OUString& rPattern, const OUString& rInput)
|
||||
UErrorCode nIcuError(U_ZERO_ERROR);
|
||||
icu::UnicodeString sIcuPattern(reinterpret_cast<const UChar*>(rPattern.getStr()), rPattern.getLength());
|
||||
icu::UnicodeString sIcuInput(reinterpret_cast<const UChar*>(rInput.getStr()), rInput.getLength());
|
||||
- RegexMatcher aMatcher(sIcuPattern, sIcuInput, 0, nIcuError);
|
||||
+ icu::RegexMatcher aMatcher(sIcuPattern, sIcuInput, 0, nIcuError);
|
||||
|
||||
return U_SUCCESS(nIcuError) && aMatcher.matches(nIcuError) && U_SUCCESS(nIcuError);
|
||||
}
|
||||
--
|
||||
cgit v1.1
|
||||
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed May 9 08:59:02 UTC 2018 - tchvatal@suse.com
|
||||
|
||||
- Extend the icu patch with more patches wrt bsc#1091772
|
||||
* libreoffice-icu61.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 9 07:57:58 UTC 2018 - tchvatal@suse.com
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user