summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2017-09-05 15:32:14 +0200
committerEike Rathke <erack@redhat.com>2017-09-05 15:41:01 +0200
commit49f1f04c5bb9922b237ec7ed6a9b58f7f1c2e781 (patch)
tree69f63d228cc0171ccbc133e85236a420ee3ad05f
parent750991d454f60d5718e17cbdcdeb4a438adfe6ab (diff)
Use LanguageTag::getBcp47MS() to write MS malformed tags to OOXML, tdf#83190
Change-Id: Id706cf40f717005df840e7856528dd7bbc866e98
-rw-r--r--oox/source/core/xmlfilterbase.cxx2
-rw-r--r--oox/source/export/drawingml.cxx2
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx2
3 files changed, 3 insertions, 3 deletions
diff --git a/oox/source/core/xmlfilterbase.cxx b/oox/source/core/xmlfilterbase.cxx
index b66dcf9e7301..e5190c512384 100644
--- a/oox/source/core/xmlfilterbase.cxx
+++ b/oox/source/core/xmlfilterbase.cxx
@@ -566,7 +566,7 @@ writeElement( const FSHelperPtr& pDoc, sal_Int32 nXmlElement, const LanguageTag&
// and obsoleted by RFC 5646, see
// http://dublincore.org/documents/dcmi-terms/#terms-language
// http://dublincore.org/documents/dcmi-terms/#elements-language
- writeElement( pDoc, nXmlElement, rLanguageTag.getBcp47() );
+ writeElement( pDoc, nXmlElement, rLanguageTag.getBcp47MS() );
}
static void
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index 3e66a504aa14..f0d3ea78431f 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -1382,7 +1382,7 @@ void DrawingML::WriteRunProperties( const Reference< XPropertySet >& rRun, bool
mAny >>= aLocale;
LanguageTag aLanguageTag( aLocale);
if (!aLanguageTag.isSystemLocale())
- usLanguage = aLanguageTag.getBcp47();
+ usLanguage = aLanguageTag.getBcp47MS();
}
if( GETAD( CharEscapement ) )
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index 1332baf8f628..f1413e5f62d7 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -6515,7 +6515,7 @@ void DocxAttributeOutput::CharKerning( const SvxKerningItem& rKerning )
void DocxAttributeOutput::CharLanguage( const SvxLanguageItem& rLanguage )
{
OString aLanguageCode( OUStringToOString(
- LanguageTag( rLanguage.GetLanguage()).getBcp47(),
+ LanguageTag( rLanguage.GetLanguage()).getBcp47MS(),
RTL_TEXTENCODING_UTF8));
switch ( rLanguage.Which() )