[Libreoffice-commits] core.git: 2 commits - basctl/source canvas/source chart2/source configmgr/source cppcanvas/source cui/source desktop/source drawinglayer/source editeng/source forms/source framework/source i18nlangtag/source include/i18nlangtag lingucomponent/source linguistic/source oox/source reportdesign/source sc/source sd/source sfx2/source starmath/source svl/source svtools/langsupport svtools/source svx/source sw/source unotools/source vcl/win writerfilter/source xmloff/source xmlscript/source

Eike Rathke erack at redhat.com
Sat Jul 13 02:56:43 PDT 2013


 basctl/source/basicide/basicbox.cxx                                |    2 
 basctl/source/dlged/managelang.cxx                                 |    6 
 canvas/source/cairo/cairo_canvasfont.cxx                           |    2 
 canvas/source/directx/dx_textlayout_drawhelper.cxx                 |    2 
 canvas/source/vcl/canvasfont.cxx                                   |    2 
 chart2/source/tools/CharacterProperties.cxx                        |    6 
 configmgr/source/configurationprovider.cxx                         |    4 
 cppcanvas/source/mtfrenderer/implrenderer.cxx                      |    2 
 cui/source/dialogs/SpellDialog.cxx                                 |    8 
 cui/source/dialogs/hangulhanjadlg.cxx                              |    2 
 cui/source/dialogs/hyphen.cxx                                      |    2 
 cui/source/dialogs/thesdlg.cxx                                     |    6 
 cui/source/options/optasian.cxx                                    |    4 
 cui/source/options/optdict.cxx                                     |    4 
 cui/source/options/optgdlg.cxx                                     |   20 -
 cui/source/options/optlingu.cxx                                    |   28 +-
 cui/source/tabpages/autocdlg.cxx                                   |   10 
 desktop/source/app/langselect.cxx                                  |    2 
 drawinglayer/source/primitive2d/textlayoutdevice.cxx               |    2 
 editeng/source/editeng/editview.cxx                                |    8 
 editeng/source/editeng/impedit3.cxx                                |    2 
 editeng/source/editeng/impedit4.cxx                                |    8 
 editeng/source/items/textitem.cxx                                  |    2 
 editeng/source/misc/hangulhanja.cxx                                |    4 
 editeng/source/misc/splwrap.cxx                                    |    2 
 editeng/source/misc/svxacorr.cxx                                   |    2 
 editeng/source/misc/unolingu.cxx                                   |    6 
 editeng/source/outliner/outlvw.cxx                                 |    2 
 editeng/source/uno/UnoForbiddenCharsTable.cxx                      |    8 
 forms/source/component/FormattedField.cxx                          |    4 
 framework/source/services/substitutepathvars.cxx                   |    2 
 i18nlangtag/source/isolang/inunx.cxx                               |    2 
 i18nlangtag/source/languagetag/languagetag.cxx                     |  126 ++++++++--
 include/i18nlangtag/languagetag.hxx                                |   68 +++++
 lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx |    2 
 lingucomponent/source/lingutil/lingutil.cxx                        |    4 
 lingucomponent/source/spellcheck/spell/sspellimp.cxx               |    4 
 lingucomponent/source/thesaurus/libnth/nthesimp.cxx                |    2 
 linguistic/source/convdic.cxx                                      |    2 
 linguistic/source/convdicxml.cxx                                   |    4 
 linguistic/source/dicimp.cxx                                       |    4 
 linguistic/source/gciterator.cxx                                   |    4 
 linguistic/source/hyphdsp.cxx                                      |    2 
 linguistic/source/hyphdta.cxx                                      |    4 
 linguistic/source/lngsvcmgr.cxx                                    |   30 +-
 linguistic/source/misc.cxx                                         |    4 
 linguistic/source/spelldsp.cxx                                     |   14 -
 linguistic/source/spelldta.cxx                                     |    2 
 linguistic/source/thesdsp.cxx                                      |    2 
 oox/source/docprop/docprophandler.cxx                              |    2 
 reportdesign/source/core/api/ReportComponent.cxx                   |    6 
 sc/source/core/tool/addincol.cxx                                   |    2 
 sc/source/filter/oox/numberformatsbuffer.cxx                       |    2 
 sc/source/ui/app/scmod2.cxx                                        |    2 
 sc/source/ui/dbgui/tpsort.cxx                                      |    6 
 sc/source/ui/docshell/docsh2.cxx                                   |    2 
 sc/source/ui/docshell/impex.cxx                                    |    4 
 sc/source/ui/unoobj/convuno.cxx                                    |    4 
 sc/source/ui/unoobj/defltuno.cxx                                   |    2 
 sd/source/ui/unoidl/unomodel.cxx                                   |    4 
 sd/source/ui/unoidl/unopool.cxx                                    |    2 
 sd/source/ui/view/drviews7.cxx                                     |    2 
 sd/source/ui/view/outlnvsh.cxx                                     |    2 
 sfx2/source/doc/SfxDocumentMetaData.cxx                            |    2 
 sfx2/source/doc/doctemplates.cxx                                   |    2 
 sfx2/source/menu/thessubmenu.cxx                                   |    2 
 starmath/source/parse.cxx                                          |    2 
 svl/source/config/asiancfg.cxx                                     |    4 
 svl/source/config/languageoptions.cxx                              |    2 
 svl/source/items/srchitem.cxx                                      |    4 
 svl/source/numbers/numfmuno.cxx                                    |    2 
 svl/source/numbers/supservs.cxx                                    |    2 
 svl/source/numbers/zforlist.cxx                                    |    2 
 svtools/langsupport/langsupport.cxx                                |    2 
 svtools/source/misc/langtab.cxx                                    |    2 
 svx/source/dialog/langbox.cxx                                      |    2 
 svx/source/form/fmcontrollayout.cxx                                |    2 
 sw/source/core/bastyp/init.cxx                                     |    2 
 sw/source/core/doc/docsort.cxx                                     |    2 
 sw/source/core/fields/authfld.cxx                                  |    2 
 sw/source/core/tox/txmsrt.cxx                                      |    2 
 sw/source/core/unocore/unoflatpara.cxx                             |    4 
 sw/source/core/unocore/unoidx.cxx                                  |    2 
 sw/source/core/unocore/unoobj.cxx                                  |    4 
 sw/source/filter/basflt/fltini.cxx                                 |    4 
 sw/source/filter/html/css1atr.cxx                                  |    2 
 sw/source/filter/html/htmlcss1.cxx                                 |    2 
 sw/source/filter/html/htmlgrin.cxx                                 |    2 
 sw/source/filter/html/wrthtml.cxx                                  |    2 
 sw/source/filter/ww8/docxattributeoutput.cxx                       |    2 
 sw/source/filter/ww8/ww8par.cxx                                    |    2 
 sw/source/ui/app/appopt.cxx                                        |    6 
 sw/source/ui/app/docshini.cxx                                      |    2 
 sw/source/ui/dbui/dbinsdlg.cxx                                     |    4 
 sw/source/ui/index/swuiidxmrk.cxx                                  |    2 
 sw/source/ui/lingu/hhcwrp.cxx                                      |    4 
 sw/source/ui/lingu/olmenu.cxx                                      |    2 
 sw/source/ui/shells/annotsh.cxx                                    |    4 
 sw/source/ui/shells/drwtxtex.cxx                                   |    4 
 sw/source/ui/uiview/viewling.cxx                                   |    2 
 sw/source/ui/uiview/viewstat.cxx                                   |    2 
 sw/source/ui/uno/unotxdoc.cxx                                      |    2 
 sw/source/ui/vba/vbastyle.cxx                                      |    2 
 unotools/source/config/lingucfg.cxx                                |   12 
 unotools/source/config/syslocaleoptions.cxx                        |    4 
 unotools/source/i18n/textsearch.cxx                                |    2 
 vcl/win/source/gdi/winlayout.cxx                                   |    2 
 writerfilter/source/dmapper/DomainMapper.cxx                       |    2 
 xmloff/source/style/xmlnumfe.cxx                                   |    4 
 xmlscript/source/xmldlg_imexp/xmldlg_impmodels.cxx                 |    2 
 110 files changed, 385 insertions(+), 231 deletions(-)

New commits:
commit 358d1a99484bcc02900bd200a7606a7bf3298cac
Author: Eike Rathke <erack at redhat.com>
Date:   Sat Jul 13 02:54:05 2013 +0200

    use static LanguageTag::convertTo...() for standalone conversions
    
    If no LanguageTag instance is at hand use the static methods to convert
    between BCP 47 string, Locale and MS-LangID instead of creating
    temporary instances.
    
    Change-Id: I9597f768078eb81c840e84a5db5617f26bb7dc09

diff --git a/basctl/source/basicide/basicbox.cxx b/basctl/source/basicide/basicbox.cxx
index 375b6ac..db86fdf 100644
--- a/basctl/source/basicide/basicbox.cxx
+++ b/basctl/source/basicide/basicbox.cxx
@@ -416,7 +416,7 @@ void LanguageBox::FillBox()
         {
             bool bIsDefault = localesAreEqual( aDefaultLocale, pLocale[i] );
             bool bIsCurrent = localesAreEqual( aCurrentLocale, pLocale[i] );
-            LanguageType eLangType = LanguageTag( pLocale[i] ).getLanguageType();
+            LanguageType eLangType = LanguageTag::convertToLanguageType( pLocale[i] );
             OUString sLanguage = aLangTable.GetString( eLangType );
             if ( bIsDefault )
             {
diff --git a/basctl/source/dlged/managelang.cxx b/basctl/source/dlged/managelang.cxx
index 1efc75e..dc5326e 100644
--- a/basctl/source/dlged/managelang.cxx
+++ b/basctl/source/dlged/managelang.cxx
@@ -170,7 +170,7 @@ void ManageLanguageDialog::FillLanguageBox()
         for ( i = 0;  i < nCount;  ++i )
         {
             bool bIsDefault = localesAreEqual( aDefaultLocale, pLocale[i] );
-            LanguageType eLangType = LanguageTag( pLocale[i] ).getLanguageType();
+            LanguageType eLangType = LanguageTag::convertToLanguageType( pLocale[i] );
             OUStringBuffer sLanguageBuf(aLangTable.GetString( eLangType ));
             if ( bIsDefault )
             {
@@ -325,7 +325,7 @@ void SetDefaultLanguageDialog::FillLanguageBox()
     const Locale* pLocale = aLocaleSeq.getConstArray();
     sal_Int32 i, nCount = aLocaleSeq.getLength();
     for ( i = 0;  i < nCount;  ++i )
-        m_pLanguageLB->RemoveLanguage( LanguageTag( pLocale[i] ).getLanguageType() );
+        m_pLanguageLB->RemoveLanguage( LanguageTag::convertToLanguageType( pLocale[i] ) );
 
     // fill checklistbox if not in default mode
     if ( m_pLocalizationMgr->isLibraryLocalized() )
@@ -390,7 +390,7 @@ Sequence< Locale > SetDefaultLanguageDialog::GetLocales() const
             if ( m_pCheckLangLB->IsChecked(i) )
             {
                 LanguageType eType = LanguageType( (sal_uLong)m_pCheckLangLB->GetEntryData(i) );
-                aLocaleSeq[j++] = LanguageTag( eType ).getLocale();
+                aLocaleSeq[j++] = LanguageTag::convertToLocale( eType );
             }
         }
         DBG_ASSERT( nSize == j, "SetDefaultLanguageDialog::GetLocales(): invalid indexes" );
diff --git a/canvas/source/cairo/cairo_canvasfont.cxx b/canvas/source/cairo/cairo_canvasfont.cxx
index e4e8d24..4c627f7 100644
--- a/canvas/source/cairo/cairo_canvasfont.cxx
+++ b/canvas/source/cairo/cairo_canvasfont.cxx
@@ -57,7 +57,7 @@ namespace cairocanvas
                 rFontRequest.FontDescription.FontDescription.Proportion == rendering::PanoseProportion::MONO_SPACED
                     ? PITCH_FIXED : PITCH_VARIABLE);
 
-        maFont->SetLanguage( LanguageTag( rFontRequest.Locale).getLanguageType( false));
+        maFont->SetLanguage( LanguageTag::convertToLanguageType( rFontRequest.Locale, false));
 
         // adjust to stretched/shrinked font
         if( !::rtl::math::approxEqual( rFontMatrix.m00, rFontMatrix.m11) )
diff --git a/canvas/source/directx/dx_textlayout_drawhelper.cxx b/canvas/source/directx/dx_textlayout_drawhelper.cxx
index 7916030..d1f76e6 100644
--- a/canvas/source/directx/dx_textlayout_drawhelper.cxx
+++ b/canvas/source/directx/dx_textlayout_drawhelper.cxx
@@ -125,7 +125,7 @@ namespace dxcanvas
                     rFontRequest.FontDescription.FontDescription.Proportion == rendering::PanoseProportion::MONO_SPACED
                     ? PITCH_FIXED : PITCH_VARIABLE);
 
-            aFont.SetLanguage(LanguageTag(rFontRequest.Locale).getLanguageType());
+            aFont.SetLanguage(LanguageTag::convertToLanguageType(rFontRequest.Locale));
 
             // setup font color
             aFont.SetColor( aColor );
diff --git a/canvas/source/vcl/canvasfont.cxx b/canvas/source/vcl/canvasfont.cxx
index 549cf3e..783ace1 100644
--- a/canvas/source/vcl/canvasfont.cxx
+++ b/canvas/source/vcl/canvasfont.cxx
@@ -59,7 +59,7 @@ namespace vclcanvas
                 rFontRequest.FontDescription.FontDescription.Proportion == rendering::PanoseProportion::MONO_SPACED
                     ? PITCH_FIXED : PITCH_VARIABLE);
 
-        maFont->SetLanguage( LanguageTag( rFontRequest.Locale).getLanguageType( false));
+        maFont->SetLanguage( LanguageTag::convertToLanguageType( rFontRequest.Locale, false));
 
         // adjust to stretched/shrinked font
         if( !::rtl::math::approxEqual( rFontMatrix.m00, rFontMatrix.m11) )
diff --git a/chart2/source/tools/CharacterProperties.cxx b/chart2/source/tools/CharacterProperties.cxx
index 40c79a3..ff8b8c9 100644
--- a/chart2/source/tools/CharacterProperties.cxx
+++ b/chart2/source/tools/CharacterProperties.cxx
@@ -409,11 +409,11 @@ void CharacterProperties::AddDefaultsToMap(
 
     using namespace ::com::sun::star::i18n::ScriptType;
     LanguageType nLang;
-    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aDefaultLocale).getLanguageType( false), LATIN);
+    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale, false), LATIN);
     Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_LATIN_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
-    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag( aDefaultLocale_CJK).getLanguageType( false), ASIAN);
+    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale_CJK, false), ASIAN);
     Font aFontCJK = OutputDevice::GetDefaultFont( DEFAULTFONT_CJK_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
-    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag( aDefaultLocale_CTL).getLanguageType( false), COMPLEX);
+    nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale_CTL, false), COMPLEX);
     Font aFontCTL = OutputDevice::GetDefaultFont( DEFAULTFONT_CTL_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
 
     ::chart::PropertyHelper::setPropertyValueDefault( rOutMap, PROP_CHAR_FONT_NAME, OUString( aFont.GetName() ) );
diff --git a/configmgr/source/configurationprovider.cxx b/configmgr/source/configurationprovider.cxx
index d5edfab..9244f98 100644
--- a/configmgr/source/configurationprovider.cxx
+++ b/configmgr/source/configurationprovider.cxx
@@ -330,14 +330,14 @@ void Service::setLocale(css::lang::Locale const & eLocale)
     throw (css::uno::RuntimeException)
 {
     osl::MutexGuard guard(*lock_);
-    locale_ = LanguageTag( eLocale).getBcp47();
+    locale_ = LanguageTag::convertToBcp47( eLocale);
 }
 
 css::lang::Locale Service::getLocale() throw (css::uno::RuntimeException) {
     osl::MutexGuard guard(*lock_);
     css::lang::Locale loc;
     if (! locale_.isEmpty()) {
-        loc = LanguageTag( locale_).getLocale( false);
+        loc = LanguageTag::convertToLocale( locale_, false);
     }
     return loc;
 }
diff --git a/cppcanvas/source/mtfrenderer/implrenderer.cxx b/cppcanvas/source/mtfrenderer/implrenderer.cxx
index 8f1dd8d..17c68c4 100644
--- a/cppcanvas/source/mtfrenderer/implrenderer.cxx
+++ b/cppcanvas/source/mtfrenderer/implrenderer.cxx
@@ -785,7 +785,7 @@ namespace cppcanvas
                     : rendering::PanoseProportion::ANYTHING;
 
             LanguageType aLang = rFont.GetLanguage();
-            aFontRequest.Locale = LanguageTag( aLang).getLocale( false);
+            aFontRequest.Locale = LanguageTag::convertToLocale( aLang, false);
 
             // setup state-local text transformation,
             // if the font be rotated
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index f4238c7..76bd8c2 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -304,7 +304,7 @@ void SpellDialog::UpdateBoxes_Impl()
     bool bIsGrammarError = false;
     if( pSpellErrorDescription )
     {
-        nAltLanguage    = LanguageTag( pSpellErrorDescription->aLocale ).getLanguageType();
+        nAltLanguage    = LanguageTag::convertToLanguageType( pSpellErrorDescription->aLocale );
         aNewWords       = pSpellErrorDescription->aSuggestions;
         bIsGrammarError = pSpellErrorDescription->bIsGrammarError;
         m_pExplainLink->SetURL( pSpellErrorDescription->sExplanationURL );
@@ -1125,7 +1125,7 @@ bool SpellDialog::GetNextSentence_Impl(bool bUseSavedSentence, bool bRecheck)
                     uno::Reference< lang::XServiceInfo > xInfo( aStart->xGrammarChecker, uno::UNO_QUERY );
                     SpellErrorDescription aDesc( true,
                         aStart->sText,
-                        LanguageTag( aStart->eLanguage ).getLocale(),
+                        LanguageTag::convertToLocale( aStart->eLanguage ),
                         aStart->aGrammarError.aSuggestions,
                         aStart->xGrammarChecker,
                         xInfo->getImplementationName(),
@@ -1599,7 +1599,7 @@ bool SentenceEditWindow_Impl::MarkNextError( bool bIgnoreCurrentError )
 
             String sReplacement(getDotReplacementString(GetErrorText(), xEntry->getReplacementText()));
 
-            ChangeMarkedWord(sReplacement, LanguageTag( pSpellErrorDescription->aLocale ).getLanguageType());
+            ChangeMarkedWord(sReplacement, LanguageTag::convertToLanguageType( pSpellErrorDescription->aLocale ));
 
             aCursor.GetIndex() = aCursor.GetIndex() + (sal_uInt16)(xEntry->getReplacementText().getLength());
         }
@@ -1738,7 +1738,7 @@ void SentenceEditWindow_Impl::RestoreCurrentError()
     {
         const SpellErrorDescription& rDesc = pAttrib->GetErrorDescription();
         if( !rDesc.sErrorText.equals( GetErrorText() ) )
-            ChangeMarkedWord(rDesc.sErrorText, LanguageTag( rDesc.aLocale ).getLanguageType());
+            ChangeMarkedWord(rDesc.sErrorText, LanguageTag::convertToLanguageType( rDesc.aLocale ));
     }
 }
 
diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx
index ffa32ff..8ef8340 100644
--- a/cui/source/dialogs/hangulhanjadlg.cxx
+++ b/cui/source/dialogs/hangulhanjadlg.cxx
@@ -1037,7 +1037,7 @@ namespace svx
                 try
                 {
                     Reference< XConversionDictionary >  xDic =
-                        m_xConversionDictionaryList->addNewDictionary( aName, LanguageTag( LANGUAGE_KOREAN ).getLocale(), ConversionDictionaryType::HANGUL_HANJA );
+                        m_xConversionDictionaryList->addNewDictionary( aName, LanguageTag::convertToLocale( LANGUAGE_KOREAN ), ConversionDictionaryType::HANGUL_HANJA );
 
                     if( xDic.is() )
                     {
diff --git a/cui/source/dialogs/hyphen.cxx b/cui/source/dialogs/hyphen.cxx
index 7e4e724..734a9e9 100644
--- a/cui/source/dialogs/hyphen.cxx
+++ b/cui/source/dialogs/hyphen.cxx
@@ -209,7 +209,7 @@ void SvxHyphenWordDialog::InitControls_Impl()
     xPossHyph = NULL;
     if (xHyphenator.is())
     {
-        lang::Locale aLocale( LanguageTag(nActLanguage).getLocale() );
+        lang::Locale aLocale( LanguageTag::convertToLocale(nActLanguage) );
         xPossHyph = xHyphenator->createPossibleHyphens( aActWord, aLocale,
                                                         uno::Sequence< beans::PropertyValue >() );
         if (xPossHyph.is())
diff --git a/cui/source/dialogs/thesdlg.cxx b/cui/source/dialogs/thesdlg.cxx
index 713bbae..7d642c8 100644
--- a/cui/source/dialogs/thesdlg.cxx
+++ b/cui/source/dialogs/thesdlg.cxx
@@ -289,7 +289,7 @@ uno::Sequence< uno::Reference< linguistic2::XMeaning > > SvxThesaurusDialog::que
 
 bool SvxThesaurusDialog::UpdateAlternativesBox_Impl()
 {
-    lang::Locale aLocale( LanguageTag( nLookUpLanguage ).getLocale() );
+    lang::Locale aLocale( LanguageTag::convertToLocale( nLookUpLanguage ) );
     uno::Sequence< uno::Reference< linguistic2::XMeaning > > aMeanings = queryMeanings_Impl(
             aLookUpText, aLocale, uno::Sequence< beans::PropertyValue >() );
     const sal_Int32 nMeanings = aMeanings.getLength();
@@ -344,7 +344,7 @@ IMPL_LINK( SvxThesaurusDialog, LanguageHdl_Impl, ListBox*, pLB )
     String aLangText( pLB->GetSelectEntry() );
     LanguageType nLang = SvtLanguageTable().GetType( aLangText );
     DBG_ASSERT( nLang != LANGUAGE_NONE && nLang != LANGUAGE_DONTKNOW, "failed to get language" );
-    if (xThesaurus->hasLocale( LanguageTag( nLang ).getLocale() ))
+    if (xThesaurus->hasLocale( LanguageTag::convertToLocale( nLang ) ))
         nLookUpLanguage = nLang;
     SetWindowTitle( nLang );
     LookUp_Impl();
@@ -496,7 +496,7 @@ SvxThesaurusDialog::SvxThesaurusDialog(
     std::vector< OUString > aLangVec;
     for (sal_Int32 i = 0;  i < nLocales; ++i)
     {
-        const LanguageType nLang = LanguageTag( pLocales[i] ).getLanguageType();
+        const LanguageType nLang = LanguageTag::convertToLanguageType( pLocales[i] );
         DBG_ASSERT( nLang != LANGUAGE_NONE && nLang != LANGUAGE_DONTKNOW, "failed to get language" );
         aLangVec.push_back( aLangTab.GetString( nLang ) );
     }
diff --git a/cui/source/options/optasian.cxx b/cui/source/options/optasian.cxx
index d035daf..a74b30a 100644
--- a/cui/source/options/optasian.cxx
+++ b/cui/source/options/optasian.cxx
@@ -201,7 +201,7 @@ sal_Bool SvxAsianLayoutPage::FillItemSet( SfxItemSet& )
             for( itElem = pImpl->aChangedLanguagesMap.begin();
                 itElem != pImpl->aChangedLanguagesMap.end(); ++itElem )
             {
-                Locale aLocale( LanguageTag( itElem->first ).getLocale());
+                Locale aLocale( LanguageTag::convertToLocale( itElem->first ));
                 if(itElem->second->bRemoved)
                     pImpl->xForbidden->removeForbiddenCharacters( aLocale );
                 else if(itElem->second->pCharacters)
@@ -378,7 +378,7 @@ IMPL_LINK(SvxAsianLayoutPage, ChangeStandardHdl, CheckBox*, pBox)
 IMPL_LINK(SvxAsianLayoutPage, ModifyHdl, Edit*, pEdit)
 {
     LanguageType eSelectLanguage = aLanguageLB.GetSelectLanguage();
-    Locale aLocale( LanguageTag( eSelectLanguage ).getLocale());
+    Locale aLocale( LanguageTag::convertToLocale( eSelectLanguage ));
     OUString sStart = aStartED.GetText();
     OUString sEnd = aEndED.GetText();
     sal_Bool bEnable = pEdit->IsEnabled();
diff --git a/cui/source/options/optdict.cxx b/cui/source/options/optdict.cxx
index 8572341..36af1fb 100644
--- a/cui/source/options/optdict.cxx
+++ b/cui/source/options/optdict.cxx
@@ -151,7 +151,7 @@ IMPL_LINK_NOARG(SvxNewDictionaryDialog, OKHdl_Impl)
                 DictionaryType_NEGATIVE : DictionaryType_POSITIVE;
         if (xDicList.is())
         {
-            lang::Locale aLocale( LanguageTag(nLang).getLocale() );
+            lang::Locale aLocale( LanguageTag::convertToLocale(nLang) );
             String aURL( linguistic::GetWritableDictionaryURL( sDict ) );
             xNewDic = Reference< XDictionary > (
                     xDicList->createDictionary( sDict, aLocale, eType, aURL ) , UNO_QUERY );
@@ -451,7 +451,7 @@ IMPL_LINK_NOARG(SvxEditDictionaryDialog, SelectLangHdl_Impl)
 
         if ( aBox.Execute() == RET_YES )
         {
-            xDic->setLocale( LanguageTag( nLang ).getLocale() );
+            xDic->setLocale( LanguageTag::convertToLocale( nLang ) );
             bool bNegativ = xDic->getDictionaryType() == DictionaryType_NEGATIVE;
 
             const String sName(
diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index 29b166a..1510a16 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -1045,7 +1045,7 @@ OfaLanguagesTabPage::OfaLanguagesTabPage( Window* pParent, const SfxItemSet& rSe
         LanguageType aLang = LANGUAGE_DONTKNOW;
         for (sal_IntPtr i=0; i<seqInstalledLanguages.getLength(); i++)
         {
-            aLang = LanguageTag(seqInstalledLanguages[i]).getLanguageType();
+            aLang = LanguageTag::convertToLanguageType(seqInstalledLanguages[i]);
             if (aLang != LANGUAGE_DONTKNOW)
             {
                 //sal_uInt16 p = m_pUserInterfaceLB->InsertLanguage(aLang);
@@ -1245,14 +1245,14 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
 
     OUString sLang = pLangConfig->aSysLocaleOptions.GetLocaleConfigString();
     LanguageType eOldLocale = (!sLang.isEmpty() ?
-        LanguageTag( sLang ).getLanguageType() : LANGUAGE_SYSTEM);
+        LanguageTag::convertToLanguageType( sLang ) : LANGUAGE_SYSTEM);
     LanguageType eNewLocale = m_pLocaleSettingLB->GetSelectLanguage();
     if ( eOldLocale != eNewLocale )
     {
         // an empty string denotes SYSTEM locale
         OUString sNewLang;
         if ( eNewLocale != LANGUAGE_SYSTEM )
-            sNewLang = LanguageTag( eNewLocale).getBcp47();
+            sNewLang = LanguageTag::convertToBcp47( eNewLocale);
 
         // locale nowadays get to AppSettings via notification
         // this will happen after releasing the lock on the ConfigurationBroadcaster at
@@ -1303,7 +1303,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
         if(!bCurrentDocCBChecked)
         {
             Any aValue;
-            Locale aLocale = LanguageTag( eSelectLang).getLocale( false );
+            Locale aLocale = LanguageTag::convertToLocale( eSelectLang, false);
             aValue <<= aLocale;
             OUString aPropName( "DefaultLocale" );
             pLangConfig->aLinguConfig.SetProperty( aPropName, aValue );
@@ -1323,7 +1323,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
         if(!bCurrentDocCBChecked)
         {
             Any aValue;
-            Locale aLocale = LanguageTag( eSelectLang).getLocale( false );
+            Locale aLocale = LanguageTag::convertToLocale( eSelectLang, false);
             aValue <<= aLocale;
             OUString aPropName( "DefaultLocale_CJK" );
             pLangConfig->aLinguConfig.SetProperty( aPropName, aValue );
@@ -1343,7 +1343,7 @@ sal_Bool OfaLanguagesTabPage::FillItemSet( SfxItemSet& rSet )
         if(!bCurrentDocCBChecked)
         {
             Any aValue;
-            Locale aLocale = LanguageTag( eSelectLang).getLocale( false );
+            Locale aLocale = LanguageTag::convertToLocale( eSelectLang, false);
             aValue <<= aLocale;
             OUString aPropName( "DefaultLocale_CTL" );
             pLangConfig->aLinguConfig.SetProperty( aPropName, aValue );
@@ -1407,7 +1407,7 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet )
 {
     OUString sLang = pLangConfig->aSysLocaleOptions.GetLocaleConfigString();
     if ( !sLang.isEmpty() )
-        m_pLocaleSettingLB->SelectLanguage(LanguageTag(sLang).getLanguageType());
+        m_pLocaleSettingLB->SelectLanguage(LanguageTag::convertToLanguageType(sLang));
     else
         m_pLocaleSettingLB->SelectLanguage( LANGUAGE_USER_SYSTEM_CONFIG );
     sal_Bool bReadonly = pLangConfig->aSysLocaleOptions.IsReadOnly(SvtSysLocaleOptions::E_LOCALE);
@@ -1473,17 +1473,17 @@ void OfaLanguagesTabPage::Reset( const SfxItemSet& rSet )
         Locale aLocale;
         aWestLang >>= aLocale;
 
-        eCurLang = LanguageTag( aLocale ).getLanguageType( false);
+        eCurLang = LanguageTag::convertToLanguageType( aLocale, false);
 
         aCJKLang = pLangConfig->aLinguConfig.GetProperty("DefaultLocale_CJK");
         aLocale = Locale();
         aCJKLang >>= aLocale;
-        eCurLangCJK = LanguageTag( aLocale ).getLanguageType( false);
+        eCurLangCJK = LanguageTag::convertToLanguageType( aLocale, false);
 
         aCTLLang = pLangConfig->aLinguConfig.GetProperty("DefaultLocale_CTL");
         aLocale = Locale();
         aCTLLang >>= aLocale;
-        eCurLangCTL = LanguageTag( aLocale ).getLanguageType( false);
+        eCurLangCTL = LanguageTag::convertToLanguageType( aLocale, false);
     }
     catch (const Exception&)
     {
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 4398ce1..b0d050d 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -96,7 +96,7 @@ static Sequence< sal_Int16 > lcl_LocaleSeqToLangSeq( const Sequence< Locale > &r
     const Locale *pSeq = rSeq.getConstArray();
     for (sal_Int32 i = 0;  i < nLen;  ++i)
     {
-        pRes[i] = LanguageTag( pSeq[i] ).getLanguageType();
+        pRes[i] = LanguageTag::convertToLanguageType( pSeq[i] );
     }
     return aRes;
 }
@@ -838,7 +838,7 @@ SvxLinguData_Impl::SvxLinguData_Impl() :
     const Locale* pAllLocales = aAllServiceLocales.getConstArray();
     for(sal_Int32 nLocale = 0; nLocale < aAllServiceLocales.getLength(); nLocale++)
     {
-        sal_Int16 nLang = LanguageTag( pAllLocales[nLocale] ).getLanguageType();
+        sal_Int16 nLang = LanguageTag::convertToLanguageType( pAllLocales[nLocale] );
 
         aCfgSvcs = xLinguSrvcMgr->getConfiguredServices(cSpell, pAllLocales[nLocale]);
         SetChecked( aCfgSvcs );
@@ -979,7 +979,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, sal_Bool bEna
             nLocales = aLocales.getLength();
             for (i = 0;  i < nLocales;  ++i)
             {
-                sal_Int16 nLang = LanguageTag( pLocale[i] ).getLanguageType();
+                sal_Int16 nLang = LanguageTag::convertToLanguageType( pLocale[i] );
                 if (!aCfgSpellTable.count( nLang ) && bEnable)
                     aCfgSpellTable[ nLang ] = Sequence< OUString >();
                 if (aCfgSpellTable.count( nLang ))
@@ -995,7 +995,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, sal_Bool bEna
             nLocales = aLocales.getLength();
             for (i = 0;  i < nLocales;  ++i)
             {
-                sal_Int16 nLang = LanguageTag( pLocale[i] ).getLanguageType();
+                sal_Int16 nLang = LanguageTag::convertToLanguageType( pLocale[i] );
                 if (!aCfgGrammarTable.count( nLang ) && bEnable)
                     aCfgGrammarTable[ nLang ] = Sequence< OUString >();
                 if (aCfgGrammarTable.count( nLang ))
@@ -1011,7 +1011,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, sal_Bool bEna
             nLocales = aLocales.getLength();
             for (i = 0;  i < nLocales;  ++i)
             {
-                sal_Int16 nLang = LanguageTag( pLocale[i] ).getLanguageType();
+                sal_Int16 nLang = LanguageTag::convertToLanguageType( pLocale[i] );
                 if (!aCfgHyphTable.count( nLang ) && bEnable)
                     aCfgHyphTable[ nLang ] = Sequence< OUString >();
                 if (aCfgHyphTable.count( nLang ))
@@ -1027,7 +1027,7 @@ void SvxLinguData_Impl::Reconfigure( const OUString &rDisplayName, sal_Bool bEna
             nLocales = aLocales.getLength();
             for (i = 0;  i < nLocales;  ++i)
             {
-                sal_Int16 nLang = LanguageTag( pLocale[i] ).getLanguageType();
+                sal_Int16 nLang = LanguageTag::convertToLanguageType( pLocale[i] );
                 if (!aCfgThesTable.count( nLang ) && bEnable)
                     aCfgThesTable[ nLang ] = Sequence< OUString >();
                 if (aCfgThesTable.count( nLang ))
@@ -1203,7 +1203,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet )
             sal_Int16 nLang = aIt->first;
             const Sequence< OUString > aImplNames( aIt->second );
             uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
-            Locale aLocale( LanguageTag(nLang).getLocale() );
+            Locale aLocale( LanguageTag::convertToLocale(nLang) );
             if (xMgr.is())
                 xMgr->setConfiguredServices( cSpell, aLocale, aImplNames );
         }
@@ -1215,7 +1215,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet )
             sal_Int16 nLang = aIt->first;
             const Sequence< OUString > aImplNames( aIt->second );
             uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
-            Locale aLocale( LanguageTag(nLang).getLocale() );
+            Locale aLocale( LanguageTag::convertToLocale(nLang) );
             if (xMgr.is())
                 xMgr->setConfiguredServices( cGrammar, aLocale, aImplNames );
         }
@@ -1227,7 +1227,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet )
             sal_Int16 nLang = aIt->first;
             const Sequence< OUString > aImplNames( aIt->second );
             uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
-            Locale aLocale( LanguageTag(nLang).getLocale() );
+            Locale aLocale( LanguageTag::convertToLocale(nLang) );
             if (xMgr.is())
                 xMgr->setConfiguredServices( cHyph, aLocale, aImplNames );
         }
@@ -1239,7 +1239,7 @@ sal_Bool SvxLinguTabPage::FillItemSet( SfxItemSet& rCoreSet )
             sal_Int16 nLang = aIt->first;
             const Sequence< OUString > aImplNames( aIt->second );
             uno::Reference< XLinguServiceManager2 > xMgr( pLinguData->GetManager() );
-            Locale aLocale( LanguageTag(nLang).getLocale() );
+            Locale aLocale( LanguageTag::convertToLocale(nLang) );
             if (xMgr.is())
                 xMgr->setConfiguredServices( cThes, aLocale, aImplNames );
         }
@@ -1631,7 +1631,7 @@ IMPL_LINK( SvxLinguTabPage, ClickHdl_Impl, PushButton *, pBtn )
         sal_Int32 nLocales = pLinguData->GetAllSupportedLocales().getLength();
         for (sal_Int32 k = 0;  k < nLocales;  ++k)
         {
-            sal_Int16 nLang = LanguageTag( pAllLocales[k] ).getLanguageType();
+            sal_Int16 nLang = LanguageTag::convertToLanguageType( pAllLocales[k] );
             if (pLinguData->GetSpellTable().count( nLang ))
                 pLinguData->SetChecked( pLinguData->GetSpellTable()[ nLang ] );
             if (pLinguData->GetGrammarTable().count( nLang ))
@@ -1983,7 +1983,7 @@ SvxEditModulesDlg::SvxEditModulesDlg(Window* pParent, SvxLinguData_Impl& rData)
     aLanguageLB.Clear();
     for(long i = 0; i < rLoc.getLength(); i++)
     {
-        sal_Int16 nLang = LanguageTag( pLocales[i] ).getLanguageType();
+        sal_Int16 nLang = LanguageTag::convertToLanguageType( pLocales[i] );
         aLanguageLB.InsertLanguage( nLang, lcl_SeqHasLang( aAvailLang, nLang ) );
     }
     LanguageType eSysLang = MsLangId::getSystemLanguage();
@@ -2092,7 +2092,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox )
 {
     LanguageType  eCurLanguage = aLanguageLB.GetSelectLanguage();
     static Locale aLastLocale;
-    Locale aCurLocale( LanguageTag( eCurLanguage).getLocale());
+    Locale aCurLocale( LanguageTag::convertToLocale( eCurLanguage));
     SvTreeList *pModel = aModulesCLB.GetModel();
 
     if (pBox)
@@ -2100,7 +2100,7 @@ IMPL_LINK( SvxEditModulesDlg, LangSelectHdl_Impl, ListBox *, pBox )
         // save old probably changed settings
         // before switching to new language entries
 
-        sal_Int16 nLang = LanguageTag( aLastLocale ).getLanguageType();
+        sal_Int16 nLang = LanguageTag::convertToLanguageType( aLastLocale );
 
         sal_Int32 nStart = 0, nLocalIndex = 0;
         Sequence< OUString > aChange;
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 9efb438..11b6c7cd 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -1366,7 +1366,7 @@ OfaAutocorrExceptPage::OfaAutocorrExceptPage(Window* pParent, const SfxItemSet&
     get(m_pDelDoublePB, "deldouble");
     get(m_pAutoCapsCB, "autodouble");
 
-    ::com::sun::star::lang::Locale aLcl( LanguageTag(eLastDialogLanguage ).getLocale());
+    ::com::sun::star::lang::Locale aLcl( LanguageTag::convertToLocale(eLastDialogLanguage ));
     pCompareClass = new CollatorWrapper( comphelper::getProcessComponentContext() );
     pCompareClass->loadDefaultCollator( aLcl, 0 );
 
@@ -1537,7 +1537,7 @@ void OfaAutocorrExceptPage::SetLanguage(LanguageType eSet)
         eLastDialogLanguage = eSet;
         delete pCompareClass;
         pCompareClass = new CollatorWrapper( comphelper::getProcessComponentContext() );
-        pCompareClass->loadDefaultCollator( LanguageTag( eLastDialogLanguage ).getLocale(), 0 );
+        pCompareClass->loadDefaultCollator( LanguageTag::convertToLocale( eLastDialogLanguage ), 0 );
         ModifyHdl(m_pAbbrevED);
         ModifyHdl(m_pDoubleCapsED);
     }
@@ -2425,7 +2425,7 @@ void OfaSmartTagOptionsTabPage::FillListBox( const SmartTagMgr& rSmartTagMgr )
 
     // fill list box:
     const sal_uInt32 nNumberOfRecognizers = rSmartTagMgr.NumberOfRecognizers();
-    const lang::Locale aLocale( LanguageTag( eLastDialogLanguage ).getLocale() );
+    const lang::Locale aLocale( LanguageTag::convertToLocale( eLastDialogLanguage ) );
 
     for ( sal_uInt32 i = 0; i < nNumberOfRecognizers; ++i )
     {
@@ -2468,7 +2468,7 @@ IMPL_LINK_NOARG(OfaSmartTagOptionsTabPage, ClickHdl)
     uno::Reference< smarttags::XSmartTagRecognizer > xRec = pUserData->mxRec;
     const sal_Int32 nSmartTagIdx = pUserData->mnSmartTagIdx;
 
-     const lang::Locale aLocale( LanguageTag( eLastDialogLanguage ).getLocale() );
+     const lang::Locale aLocale( LanguageTag::convertToLocale( eLastDialogLanguage ) );
     if ( xRec->hasPropertyPage( nSmartTagIdx, aLocale ) )
         xRec->displayPropertyPage( nSmartTagIdx, aLocale );
 
@@ -2507,7 +2507,7 @@ IMPL_LINK_NOARG(OfaSmartTagOptionsTabPage, SelectHdl)
     uno::Reference< smarttags::XSmartTagRecognizer > xRec = pUserData->mxRec;
     const sal_Int32 nSmartTagIdx = pUserData->mnSmartTagIdx;
 
-    const lang::Locale aLocale( LanguageTag( eLastDialogLanguage ).getLocale() );
+    const lang::Locale aLocale( LanguageTag::convertToLocale( eLastDialogLanguage ) );
     if ( xRec->hasPropertyPage( nSmartTagIdx, aLocale ) )
         m_aPropertiesPB.Enable( sal_True );
     else
diff --git a/desktop/source/app/langselect.cxx b/desktop/source/app/langselect.cxx
index d89174e..d701ee4 100644
--- a/desktop/source/app/langselect.cxx
+++ b/desktop/source/app/langselect.cxx
@@ -241,7 +241,7 @@ void LanguageSelection::setDefaultLanguage(const OUString& sLocale)
     // See #i42730# for rules for determining source of settings
 
     // determine script type of locale
-    LanguageType nLang = LanguageTag(sLocale).getLanguageType();
+    LanguageType nLang = LanguageTag::convertToLanguageType(sLocale);
     sal_uInt16 nScriptType = SvtLanguageOptions::GetScriptTypeOfLanguage(nLang);
 
     switch (nScriptType)
diff --git a/drawinglayer/source/primitive2d/textlayoutdevice.cxx b/drawinglayer/source/primitive2d/textlayoutdevice.cxx
index 69f042e..abe3325 100644
--- a/drawinglayer/source/primitive2d/textlayoutdevice.cxx
+++ b/drawinglayer/source/primitive2d/textlayoutdevice.cxx
@@ -403,7 +403,7 @@ namespace drawinglayer
             aRetval.SetItalic(rFontAttribute.getItalic() ? ITALIC_NORMAL : ITALIC_NONE);
             aRetval.SetOutline(rFontAttribute.getOutline());
             aRetval.SetPitch(rFontAttribute.getMonospaced() ? PITCH_FIXED : PITCH_VARIABLE);
-            aRetval.SetLanguage(LanguageTag(rLocale).getLanguageType(false));
+            aRetval.SetLanguage(LanguageTag::convertToLanguageType( rLocale, false));
 
 #ifdef WIN32
             // for WIN32 systems, correct the FontWidth if FontScaling is used
diff --git a/editeng/source/editeng/editview.cxx b/editeng/source/editeng/editview.cxx
index e5f45e7..17d9fb1 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -129,10 +129,10 @@ LanguageType EditView::CheckLanguage(
         // en-US
         aLangList[3] = LANGUAGE_ENGLISH_US;
 #ifdef DEBUG
-        lang::Locale a0( LanguageTag( aLangList[0] ).getLocale() );
-        lang::Locale a1( LanguageTag( aLangList[1] ).getLocale() );
-        lang::Locale a2( LanguageTag( aLangList[2] ).getLocale() );
-        lang::Locale a3( LanguageTag( aLangList[3] ).getLocale() );
+        lang::Locale a0( LanguageTag::convertToLocale( aLangList[0] ) );
+        lang::Locale a1( LanguageTag::convertToLocale( aLangList[1] ) );
+        lang::Locale a2( LanguageTag::convertToLocale( aLangList[2] ) );
+        lang::Locale a3( LanguageTag::convertToLocale( aLangList[3] ) );
 #endif
 
         sal_Int32 nCount = sizeof (aLangList) / sizeof (aLangList[0]);
diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx
index 9a82eb3..f2579f8 100644
--- a/editeng/source/editeng/impedit3.cxx
+++ b/editeng/source/editeng/impedit3.cxx
@@ -1781,7 +1781,7 @@ void ImpEditEngine::ImpBreakLine( ParaPortion* pParaPortion, EditLine* pLine, Te
         i18n::LineBreakHyphenationOptions aHyphOptions( xHyph, Sequence< PropertyValue >(), 1 );
         i18n::LineBreakUserOptions aUserOptions;
 
-        const i18n::ForbiddenCharacters* pForbidden = GetForbiddenCharsTable()->GetForbiddenCharacters( LanguageTag( aLocale ).getLanguageType(), sal_True );
+        const i18n::ForbiddenCharacters* pForbidden = GetForbiddenCharsTable()->GetForbiddenCharacters( LanguageTag::convertToLanguageType( aLocale ), sal_True );
         aUserOptions.forbiddenBeginCharacters = pForbidden->beginLine;
         aUserOptions.forbiddenEndCharacters = pForbidden->endLine;
         aUserOptions.applyForbiddenRules = ((const SfxBoolItem&)pNode->GetContentAttribs().GetItem( EE_PARA_FORBIDDENRULES )).GetValue();
diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx
index 0252b8d..72b4c83 100644
--- a/editeng/source/editeng/impedit4.cxx
+++ b/editeng/source/editeng/impedit4.cxx
@@ -1504,7 +1504,7 @@ sal_Bool ImpEditEngine::HasConvertibleTextPortion( LanguageType nSrcLang )
                 ++nStart;
             LanguageType nLangFound = pEditEngine->GetLanguage( k, nStart );
 #ifdef DEBUG
-            lang::Locale aLocale( LanguageTag( nLangFound ).getLocale() );
+            lang::Locale aLocale( LanguageTag::convertToLocale( nLangFound ) );
 #endif
             bHasConvTxt =   (nSrcLang == nLangFound) ||
                             (editeng::HangulHanjaConversion::IsChinese( nLangFound ) &&
@@ -1569,8 +1569,8 @@ void ImpEditEngine::Convert( EditView* pEditView,
 
     TextConvWrapper aWrp( Application::GetDefDialogParent(),
                           ::comphelper::getProcessComponentContext(),
-                          LanguageTag( nSrcLang ).getLocale(),
-                          LanguageTag( nDestLang ).getLocale(),
+                          LanguageTag::convertToLocale( nSrcLang ),
+                          LanguageTag::convertToLocale( nDestLang ),
                           pDestFont,
                           nOptions, bIsInteractive,
                           bIsStart, pEditView );
@@ -1696,7 +1696,7 @@ void ImpEditEngine::ImpConvert( OUString &rConvTxt, LanguageType &rConvTxtLang,
             sal_uInt16 nLangIdx = nEnd > nStart ? nStart + 1 : nStart;
             LanguageType nLangFound = pEditEngine->GetLanguage( aCurStart.nPara, nLangIdx );
 #ifdef DEBUG
-            lang::Locale aLocale( LanguageTag( nLangFound ).getLocale() );
+            lang::Locale aLocale( LanguageTag::convertToLocale( nLangFound ) );
 #endif
             sal_Bool bLangOk =  (nLangFound == nSrcLang) ||
                                 (editeng::HangulHanjaConversion::IsChinese( nLangFound ) &&
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index 6c666e3..2918b22 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -2631,7 +2631,7 @@ bool SvxLanguageItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId )
             if(!(rVal >>= aLocale))
                 return sal_False;
 
-            SetValue( LanguageTag( aLocale ).getLanguageType( false));
+            SetValue( LanguageTag::convertToLanguageType( aLocale, false));
         }
         break;
     }
diff --git a/editeng/source/misc/hangulhanja.cxx b/editeng/source/misc/hangulhanja.cxx
index 15f9acb..010f21d 100644
--- a/editeng/source/misc/hangulhanja.cxx
+++ b/editeng/source/misc/hangulhanja.cxx
@@ -241,8 +241,8 @@ namespace editeng
 , m_pUIParent( _pUIParent )
 , m_xContext( rxContext )
 , m_aSourceLocale( _rSourceLocale )
-, m_nSourceLang( LanguageTag( _rSourceLocale ).getLanguageType() )
-, m_nTargetLang( LanguageTag( _rTargetLocale ).getLanguageType() )
+, m_nSourceLang( LanguageTag::convertToLanguageType( _rSourceLocale ) )
+, m_nTargetLang( LanguageTag::convertToLanguageType( _rTargetLocale ) )
 , m_pTargetFont( _pTargetFont )
 , m_bIsInteractive( _bIsInteractive )
 , m_pAntiImpl( _pAntiImpl )
diff --git a/editeng/source/misc/splwrap.cxx b/editeng/source/misc/splwrap.cxx
index 3189984..01816b4 100644
--- a/editeng/source/misc/splwrap.cxx
+++ b/editeng/source/misc/splwrap.cxx
@@ -228,7 +228,7 @@ sal_Int16 SvxSpellWrapper::CheckHyphLang(
     if (SVX_LANG_NEED_CHECK == ((nVal >> 8) & 0x00FF))
     {
         sal_uInt16 nTmpVal = SVX_LANG_MISSING_DO_WARN;
-        if (xHyph.is()  &&  xHyph->hasLocale( LanguageTag( nLang ).getLocale() ))
+        if (xHyph.is()  &&  xHyph->hasLocale( LanguageTag::convertToLocale( nLang ) ))
             nTmpVal = SVX_LANG_OK;
         nVal &= 0x00FF;
         nVal |= nTmpVal << 8;
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index d06b9d2..d40f481 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -1847,7 +1847,7 @@ sal_Bool SvxAutoCorrect::FindInCplSttExceptList(LanguageType eLang,
 OUString SvxAutoCorrect::GetAutoCorrFileName( LanguageType eLang,
                                             sal_Bool bNewFile, sal_Bool bTst ) const
 {
-    OUString sRet, sExt( LanguageTag( eLang ).getBcp47() );
+    OUString sRet, sExt( LanguageTag::convertToBcp47( eLang ) );
 
     sExt = "_" + sExt + ".dat";
     if( bNewFile )
diff --git a/editeng/source/misc/unolingu.cxx b/editeng/source/misc/unolingu.cxx
index a8554d1..9dced46 100644
--- a/editeng/source/misc/unolingu.cxx
+++ b/editeng/source/misc/unolingu.cxx
@@ -130,7 +130,7 @@ void ThesDummy_Impl::GetCfgLocales()
         Locale *pLocale = pLocaleSeq->getArray();
         for (sal_Int32 i = 0;  i < nLen;  ++i)
         {
-            pLocale[i] = LanguageTag( pNodeNames[i] ).getLocale();
+            pLocale[i] = LanguageTag::convertToLocale( pNodeNames[i] );
         }
     }
 }
@@ -677,7 +677,7 @@ uno::Reference< XDictionary > LinguMgr::GetChangeAll()
         xChangeAll = uno::Reference< XDictionary > (
                         _xDicList->createDictionary(
                             "ChangeAllList",
-                            LanguageTag( LANGUAGE_NONE ).getLocale(),
+                            LanguageTag::convertToLocale( LANGUAGE_NONE ),
                             DictionaryType_NEGATIVE, String() ), UNO_QUERY );
     }
     return xChangeAll;
@@ -705,7 +705,7 @@ uno::Reference< XDictionary > LinguMgr::GetStandard()
         try
         {
             xTmp =  xTmpDicList->createDictionary( aDicName,
-                        LanguageTag( LANGUAGE_NONE ).getLocale(),
+                        LanguageTag::convertToLocale( LANGUAGE_NONE ),
                         DictionaryType_POSITIVE,
                         linguistic::GetWritableDictionaryURL( aDicName ) );
         }
diff --git a/editeng/source/outliner/outlvw.cxx b/editeng/source/outliner/outlvw.cxx
index c1b8fa8..a72f2bc 100644
--- a/editeng/source/outliner/outlvw.cxx
+++ b/editeng/source/outliner/outlvw.cxx
@@ -1575,7 +1575,7 @@ bool EDITENG_DLLPUBLIC GetStatusValueForThesaurusFromContext(
     aText = pEditEngine->GetText( aTextSel );
     aTextSel.Adjust();
     LanguageType nLang = pEditEngine->GetLanguage( aTextSel.nStartPara, aTextSel.nStartPos );
-    OUString aLangText( LanguageTag( nLang ).getBcp47() );
+    OUString aLangText( LanguageTag::convertToBcp47( nLang ) );
 
     // set word and locale to look up as status value
     OUString aStatusVal= aText + "#" + aLangText;
diff --git a/editeng/source/uno/UnoForbiddenCharsTable.cxx b/editeng/source/uno/UnoForbiddenCharsTable.cxx
index 12dcee9..08d29aa 100644
--- a/editeng/source/uno/UnoForbiddenCharsTable.cxx
+++ b/editeng/source/uno/UnoForbiddenCharsTable.cxx
@@ -52,7 +52,7 @@ ForbiddenCharacters SvxUnoForbiddenCharsTable::getForbiddenCharacters( const Loc
     if(!mxForbiddenChars.is())
         throw RuntimeException();
 
-    const LanguageType eLang = LanguageTag( rLocale ).getLanguageType();
+    const LanguageType eLang = LanguageTag::convertToLanguageType( rLocale );
     const ForbiddenCharacters* pForbidden = mxForbiddenChars->GetForbiddenCharacters( eLang, sal_False );
     if(!pForbidden)
         throw NoSuchElementException();
@@ -68,7 +68,7 @@ sal_Bool SvxUnoForbiddenCharsTable::hasForbiddenCharacters( const Locale& rLocal
     if(!mxForbiddenChars.is())
         return sal_False;
 
-    const LanguageType eLang = LanguageTag( rLocale ).getLanguageType();
+    const LanguageType eLang = LanguageTag::convertToLanguageType( rLocale );
     const ForbiddenCharacters* pForbidden = mxForbiddenChars->GetForbiddenCharacters( eLang, sal_False );
 
     return NULL != pForbidden;
@@ -82,7 +82,7 @@ void SvxUnoForbiddenCharsTable::setForbiddenCharacters(const Locale& rLocale, co
     if(!mxForbiddenChars.is())
         throw RuntimeException();
 
-    const LanguageType eLang = LanguageTag( rLocale ).getLanguageType();
+    const LanguageType eLang = LanguageTag::convertToLanguageType( rLocale );
     mxForbiddenChars->SetForbiddenCharacters( eLang, rForbiddenCharacters );
 
     onChange();
@@ -96,7 +96,7 @@ void SvxUnoForbiddenCharsTable::removeForbiddenCharacters( const Locale& rLocale
     if(!mxForbiddenChars.is())
         throw RuntimeException();
 
-    const LanguageType eLang = LanguageTag( rLocale ).getLanguageType();
+    const LanguageType eLang = LanguageTag::convertToLanguageType( rLocale );
     mxForbiddenChars->ClearForbiddenCharacters( eLang );
 
     onChange();
diff --git a/forms/source/component/FormattedField.cxx b/forms/source/component/FormattedField.cxx
index 773c7a5..8e74136 100644
--- a/forms/source/component/FormattedField.cxx
+++ b/forms/source/component/FormattedField.cxx
@@ -845,7 +845,7 @@ void OFormattedModel::write(const Reference<XObjectOutputStream>& _rxOutStream)
             if (isA(aLocale, static_cast<Locale*>(NULL)))
             {
                 Locale* pLocale = (Locale*)aLocale.getValue();
-                eFormatLanguage = LanguageTag( *pLocale ).getLanguageType( false);
+                eFormatLanguage = LanguageTag::convertToLanguageType( *pLocale, false);
             }
         }
 
@@ -928,7 +928,7 @@ void OFormattedModel::read(const Reference<XObjectInputStream>& _rxInStream) thr
 
                 if (xFormats.is())
                 {
-                    Locale aDescriptionLanguage( LanguageTag(eDescriptionLanguage).getLocale());
+                    Locale aDescriptionLanguage( LanguageTag::convertToLocale(eDescriptionLanguage));
 
                     nKey = xFormats->queryKey(sFormatDescription, aDescriptionLanguage, sal_False);
                     if (nKey == (sal_Int32)-1)
diff --git a/framework/source/services/substitutepathvars.cxx b/framework/source/services/substitutepathvars.cxx
index d012b6d..ac75295 100644
--- a/framework/source/services/substitutepathvars.cxx
+++ b/framework/source/services/substitutepathvars.cxx
@@ -1187,7 +1187,7 @@ void SubstitutePathVariables::SetPredefinedPathVariables( PredefinedPathVariable
     // Detect the language type of the current office
     aPreDefPathVariables.m_eLanguageType = LANGUAGE_ENGLISH_US;
     OUString aLocaleStr( utl::ConfigManager::getLocale() );
-    aPreDefPathVariables.m_eLanguageType = LanguageTag( aLocaleStr ).getLanguageType();
+    aPreDefPathVariables.m_eLanguageType = LanguageTag::convertToLanguageType( aLocaleStr );
     // We used to have an else branch here with a LOG_ERROR, but that
     // always fired in some unit tests when this code was built with
     // debug=t, so it seems fairly pointless, especially as
diff --git a/i18nlangtag/source/isolang/inunx.cxx b/i18nlangtag/source/isolang/inunx.cxx
index a20a64d..9e30a8f 100644
--- a/i18nlangtag/source/isolang/inunx.cxx
+++ b/i18nlangtag/source/isolang/inunx.cxx
@@ -99,7 +99,7 @@ static void getPlatformSystemLanguageImpl( LanguageType& rSystemLanguage,
 
             if ( osl_getProcessLocale(&procLocale) == osl_Process_E_None )
             {
-                nLang = LanguageTag( *procLocale ).getLanguageType();
+                nLang = LanguageTag::convertToLanguageType( *procLocale );
                 OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
                 rSystemLanguage = nLang;
 #ifdef DEBUG
diff --git a/lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx b/lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx
index 5a9526f..df80e39 100644
--- a/lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx
+++ b/lingucomponent/source/hyphenator/altlinuxhyph/hyphen/hyphenimp.cxx
@@ -165,7 +165,7 @@ Sequence< Locale > SAL_CALL Hyphenator::getLocales()
             k = 0;
             for (aItB = aLocaleNamesSet.begin();  aItB != aLocaleNamesSet.end();  ++aItB)
             {
-                Locale aTmp( LanguageTag( *aItB ).getLocale());
+                Locale aTmp( LanguageTag::convertToLocale( *aItB ));
                 aSuppLocales[k++] = aTmp;
             }
 
diff --git a/lingucomponent/source/lingutil/lingutil.cxx b/lingucomponent/source/lingutil/lingutil.cxx
index bd107fa..f8ae521 100644
--- a/lingucomponent/source/lingutil/lingutil.cxx
+++ b/lingucomponent/source/lingutil/lingutil.cxx
@@ -198,7 +198,7 @@ void MergeNewStyleDicsAndOldStyleDics(
         sal_Int32 nLocaleNames = aLocaleNames.getLength();
         for (sal_Int32 k = 0;  k < nLocaleNames; ++k)
         {
-            LanguageType nLang = LanguageTag( aLocaleNames[k] ).getLanguageType();
+            LanguageType nLang = LanguageTag::convertToLanguageType( aLocaleNames[k] );
             aNewStyleLanguages.insert( nLang );
         }
     }
@@ -214,7 +214,7 @@ void MergeNewStyleDicsAndOldStyleDics(
         DBG_ASSERT( nOldStyleDics, "old style dictionary with more then one language found!");
         if (nOldStyleDics > 0)
         {
-            LanguageType nLang = LanguageTag( aIt2->aLocaleNames[0] ).getLanguageType();
+            LanguageType nLang = LanguageTag::convertToLanguageType( aIt2->aLocaleNames[0] );
 
             if (nLang == LANGUAGE_DONTKNOW || linguistic::LinguIsUnspecified( nLang))
             {
diff --git a/lingucomponent/source/spellcheck/spell/sspellimp.cxx b/lingucomponent/source/spellcheck/spell/sspellimp.cxx
index 2e4e7e6..1acdf0d 100644
--- a/lingucomponent/source/spellcheck/spell/sspellimp.cxx
+++ b/lingucomponent/source/spellcheck/spell/sspellimp.cxx
@@ -165,7 +165,7 @@ Sequence< Locale > SAL_CALL SpellChecker::getLocales()
             k = 0;
             for (aItB = aLocaleNamesSet.begin();  aItB != aLocaleNamesSet.end();  ++aItB)
             {
-                Locale aTmp( LanguageTag( *aItB ).getLocale());
+                Locale aTmp( LanguageTag::convertToLocale( *aItB ));
                 aSuppLocales[k++] = aTmp;
             }
 
@@ -199,7 +199,7 @@ Sequence< Locale > SAL_CALL SpellChecker::getLocales()
                     {
                         aDicts[k]  = NULL;
                         aDEncs[k]  = RTL_TEXTENCODING_DONTKNOW;
-                        aDLocs[k]  = LanguageTag( aLocaleNames[i] ).getLocale();
+                        aDLocs[k]  = LanguageTag::convertToLocale( aLocaleNames[i] );
                         // also both files have to be in the same directory and the
                         // file names must only differ in the extension (.aff/.dic).
                         // Thus we use the first location only and strip the extension part.
diff --git a/lingucomponent/source/thesaurus/libnth/nthesimp.cxx b/lingucomponent/source/thesaurus/libnth/nthesimp.cxx
index 69bc07b..4bf271d 100644
--- a/lingucomponent/source/thesaurus/libnth/nthesimp.cxx
+++ b/lingucomponent/source/thesaurus/libnth/nthesimp.cxx
@@ -187,7 +187,7 @@ Sequence< Locale > SAL_CALL Thesaurus::getLocales()
             k = 0;
             for (aItB = aLocaleNamesSet.begin();  aItB != aLocaleNamesSet.end();  ++aItB)
             {
-                Locale aTmp( LanguageTag( *aItB ).getLocale());
+                Locale aTmp( LanguageTag::convertToLocale( *aItB ));
                 aSuppLocales[k++] = aTmp;
             }
 
diff --git a/linguistic/source/convdic.cxx b/linguistic/source/convdic.cxx
index c21df30..323422a 100644
--- a/linguistic/source/convdic.cxx
+++ b/linguistic/source/convdic.cxx
@@ -357,7 +357,7 @@ Locale SAL_CALL ConvDic::getLocale(  )
     throw (RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return LanguageTag( nLanguage ).getLocale();
+    return LanguageTag::convertToLocale( nLanguage );
 }
 
 
diff --git a/linguistic/source/convdicxml.cxx b/linguistic/source/convdicxml.cxx
index efb73c8..91a30d3 100644
--- a/linguistic/source/convdicxml.cxx
+++ b/linguistic/source/convdicxml.cxx
@@ -223,7 +223,7 @@ void ConvDicXMLDictionaryContext_Impl::StartElement(
         OUString aValue = rxAttrList->getValueByIndex(i);
 
         if ( nPrefix == XML_NAMESPACE_TCD && aLocalName == "lang" )
-            nLanguage = LanguageTag( aValue ).getLanguageType();
+            nLanguage = LanguageTag::convertToLanguageType( aValue );
         else if ( nPrefix == XML_NAMESPACE_TCD && aLocalName == "conversion-type" )
             nConversionType = GetConversionTypeFromText( aValue );
     }
@@ -325,7 +325,7 @@ sal_uInt32 ConvDicXMLExport::exportDoc( enum ::xmloff::token::XMLTokenEnum /*eCl
                   _GetNamespaceMap().GetNameByKey( XML_NAMESPACE_TCD ) );
     AddAttributeASCII( XML_NAMESPACE_TCD, "package", "org.openoffice.Office" );
 
-    OUString aIsoLang( LanguageTag( rDic.nLanguage ).getBcp47() );
+    OUString aIsoLang( LanguageTag::convertToBcp47( rDic.nLanguage ) );
     AddAttribute( XML_NAMESPACE_TCD, "lang", aIsoLang );
     OUString aConvType( ConversionTypeToText( rDic.nConversionType ) );
     AddAttribute( XML_NAMESPACE_TCD, "conversion-type", aConvType );
diff --git a/linguistic/source/dicimp.cxx b/linguistic/source/dicimp.cxx
index 5af73a8..ca490f4 100644
--- a/linguistic/source/dicimp.cxx
+++ b/linguistic/source/dicimp.cxx
@@ -472,7 +472,7 @@ sal_uLong DictionaryNeo::saveEntries(const OUString &rURL)
     else
     {
         OStringBuffer aLine(RTL_CONSTASCII_STRINGPARAM("lang: "));
-        aLine.append(OUStringToOString(LanguageTag(nLanguage).getBcp47(), eEnc));
+        aLine.append(OUStringToOString(LanguageTag::convertToBcp47(nLanguage), eEnc));
         pStream->WriteLine(aLine.makeStringAndClear());
     }
     if (0 != (nErr = pStream->GetError()))
@@ -818,7 +818,7 @@ Locale SAL_CALL DictionaryNeo::getLocale(  )
         throw(RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return LanguageTag( nLanguage ).getLocale();
+    return LanguageTag::convertToLocale( nLanguage );
 }
 
 void SAL_CALL DictionaryNeo::setLocale( const Locale& aLocale )
diff --git a/linguistic/source/gciterator.cxx b/linguistic/source/gciterator.cxx
index 4c08a9e..d701126 100644
--- a/linguistic/source/gciterator.cxx
+++ b/linguistic/source/gciterator.cxx
@@ -444,7 +444,7 @@ uno::Reference< linguistic2::XProofreader > GrammarCheckingIterator::GetGrammarC
         m_bGCServicesChecked = sal_True;
     }
 
-    const LanguageType nLang = LanguageTag( rLocale ).getLanguageType( false);
+    const LanguageType nLang = LanguageTag::convertToLanguageType( rLocale, false);
     GCImplNames_t::const_iterator aLangIt( m_aGCImplNamesByLang.find( nLang ) );
     if (aLangIt != m_aGCImplNamesByLang.end())  // matching configured language found?
     {
@@ -1012,7 +1012,7 @@ void GrammarCheckingIterator::GetConfiguredGCSvcs_Impl()
                 {
                     // only the first entry is used, there should be only one grammar checker per language
                     const OUString aImplName( aImplNames[0] );
-                    const LanguageType nLang = LanguageTag( pElementNames[i] ).getLanguageType();
+                    const LanguageType nLang = LanguageTag::convertToLanguageType( pElementNames[i] );
                     aTmpGCImplNamesByLang[ nLang ] = aImplName;
                 }
             }
diff --git a/linguistic/source/hyphdsp.cxx b/linguistic/source/hyphdsp.cxx
index 7b5c0a9..3e5c260 100644
--- a/linguistic/source/hyphdsp.cxx
+++ b/linguistic/source/hyphdsp.cxx
@@ -224,7 +224,7 @@ Sequence< Locale > SAL_CALL HyphenatorDispatcher::getLocales()
     HyphSvcByLangMap_t::const_iterator aIt;
     for (aIt = aSvcMap.begin();  aIt != aSvcMap.end();  ++aIt)
     {
-        *pLocales++ = LanguageTag( aIt->first ).getLocale();
+        *pLocales++ = LanguageTag::convertToLocale( aIt->first );
     }
     return aLocales;
 }
diff --git a/linguistic/source/hyphdta.cxx b/linguistic/source/hyphdta.cxx
index 76d91ef..f5ce5b1 100644
--- a/linguistic/source/hyphdta.cxx
+++ b/linguistic/source/hyphdta.cxx
@@ -83,7 +83,7 @@ Locale SAL_CALL HyphenatedWord::getLocale()
 {
     MutexGuard  aGuard( GetLinguMutex() );
 
-    return LanguageTag( nLanguage ).getLocale();
+    return LanguageTag::convertToLocale( nLanguage );
 }
 
 
@@ -149,7 +149,7 @@ Locale SAL_CALL PossibleHyphens::getLocale()
         throw(RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return LanguageTag( nLanguage ).getLocale();
+    return LanguageTag::convertToLocale( nLanguage );
 }
 
 
diff --git a/linguistic/source/lngsvcmgr.cxx b/linguistic/source/lngsvcmgr.cxx
index 3cb177d..e3d4639 100644
--- a/linguistic/source/lngsvcmgr.cxx
+++ b/linguistic/source/lngsvcmgr.cxx
@@ -137,7 +137,7 @@ static uno::Sequence< lang::Locale > GetAvailLocales(
         for (i = 0;  aIt != aLanguages.end();  ++aIt, ++i)
         {
             LanguageType nLang = *aIt;
-            pRes[i] = LanguageTag( nLang ).getLocale();
+            pRes[i] = LanguageTag::convertToLocale( nLang );
         }
     }
 
@@ -612,7 +612,7 @@ namespace
     {
         Sequence< OUString > aRes;
 
-        OUString aCfgLocaleStr( LanguageTag( rAvailLocale ).getBcp47() );
+        OUString aCfgLocaleStr( LanguageTag::convertToBcp47( rAvailLocale ) );
 
         Sequence< OUString > aNodeNames( rCfg.GetNodeNames(rLastFoundList) );
         sal_Bool bFound = lcl_FindEntry( aCfgLocaleStr, aNodeNames);
@@ -880,10 +880,10 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
 
                 LanguageType nLang = LANGUAGE_NONE;
                 if (!aKeyText.isEmpty())
-                    nLang = LanguageTag( aKeyText ).getLanguageType();
+                    nLang = LanguageTag::convertToLanguageType( aKeyText );
 
                 GetSpellCheckerDsp_Impl( sal_False );     // don't set service list, it will be done below
-                pSpellDsp->SetServiceList( LanguageTag(nLang).getLocale(), aSvcImplNames );
+                pSpellDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
             }
         }
         else if (rName.startsWith( aGrammarCheckerList ))
@@ -905,12 +905,12 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
 
                 LanguageType nLang = LANGUAGE_NONE;
                 if (!aKeyText.isEmpty())
-                    nLang = LanguageTag( aKeyText ).getLanguageType();
+                    nLang = LanguageTag::convertToLanguageType( aKeyText );
 
                 if (SvtLinguConfig().HasGrammarChecker())
                 {
                     GetGrammarCheckerDsp_Impl( sal_False );   // don't set service list, it will be done below
-                    pGrammarDsp->SetServiceList( LanguageTag(nLang).getLocale(), aSvcImplNames );
+                    pGrammarDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
                 }
             }
         }
@@ -933,10 +933,10 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
 
                 LanguageType nLang = LANGUAGE_NONE;
                 if (!aKeyText.isEmpty())
-                    nLang = LanguageTag( aKeyText ).getLanguageType();
+                    nLang = LanguageTag::convertToLanguageType( aKeyText );
 
                 GetHyphenatorDsp_Impl( sal_False );   // don't set service list, it will be done below
-                pHyphDsp->SetServiceList( LanguageTag(nLang).getLocale(), aSvcImplNames );
+                pHyphDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
             }
         }
         else if (rName.startsWith( aThesaurusList ))
@@ -958,10 +958,10 @@ void LngSvcMgr::Notify( const uno::Sequence< OUString > &rPropertyNames )
 
                 LanguageType nLang = LANGUAGE_NONE;
                 if (!aKeyText.isEmpty())
-                    nLang = LanguageTag( aKeyText ).getLanguageType();
+                    nLang = LanguageTag::convertToLanguageType( aKeyText );
 
                 GetThesaurusDsp_Impl( sal_False );  // don't set service list, it will be done below
-                pThesDsp->SetServiceList( LanguageTag(nLang).getLocale(), aSvcImplNames );
+                pThesDsp->SetServiceList( LanguageTag::convertToLocale(nLang), aSvcImplNames );
             }
         }
         else
@@ -1312,7 +1312,7 @@ void LngSvcMgr::SetCfgServiceLists( SpellCheckerDispatcher &rSpellDsp )
                 String aLocaleStr( pNames[i] );
                 xub_StrLen nSeparatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
                 aLocaleStr = aLocaleStr.Copy( nSeparatorPos + 1 );
-                rSpellDsp.SetServiceList( LanguageTag(aLocaleStr).getLocale(), aSvcImplNames );
+                rSpellDsp.SetServiceList( LanguageTag::convertToLocale(aLocaleStr), aSvcImplNames );
             }
         }
     }
@@ -1354,7 +1354,7 @@ void LngSvcMgr::SetCfgServiceLists( GrammarCheckingIterator &rGrammarDsp )
                 String aLocaleStr( pNames[i] );
                 xub_StrLen nSeparatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
                 aLocaleStr = aLocaleStr.Copy( nSeparatorPos + 1 );
-                rGrammarDsp.SetServiceList( LanguageTag(aLocaleStr).getLocale(), aSvcImplNames );
+                rGrammarDsp.SetServiceList( LanguageTag::convertToLocale(aLocaleStr), aSvcImplNames );
             }
         }
     }
@@ -1396,7 +1396,7 @@ void LngSvcMgr::SetCfgServiceLists( HyphenatorDispatcher &rHyphDsp )
                 String aLocaleStr( pNames[i] );
                 xub_StrLen nSeparatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
                 aLocaleStr = aLocaleStr.Copy( nSeparatorPos + 1 );
-                rHyphDsp.SetServiceList( LanguageTag(aLocaleStr).getLocale(), aSvcImplNames );
+                rHyphDsp.SetServiceList( LanguageTag::convertToLocale(aLocaleStr), aSvcImplNames );
             }
         }
     }
@@ -1434,7 +1434,7 @@ void LngSvcMgr::SetCfgServiceLists( ThesaurusDispatcher &rThesDsp )
                 String aLocaleStr( pNames[i] );
                 xub_StrLen nSeparatorPos = aLocaleStr.SearchBackward( sal_Unicode( '/' ) );
                 aLocaleStr = aLocaleStr.Copy( nSeparatorPos + 1 );
-                rThesDsp.SetServiceList( LanguageTag(aLocaleStr).getLocale(), aSvcImplNames );
+                rThesDsp.SetServiceList( LanguageTag::convertToLocale(aLocaleStr), aSvcImplNames );
             }
         }
     }
@@ -1904,7 +1904,7 @@ uno::Sequence< OUString > SAL_CALL
 
     uno::Sequence< OUString > aSvcImplNames;
 
-    OUString aCfgLocale( LanguageTag( rLocale).getBcp47() );
+    OUString aCfgLocale( LanguageTag::convertToBcp47( rLocale) );
 
     uno::Sequence< uno::Any > aValues;
     uno::Sequence< OUString > aNames( 1 );
diff --git a/linguistic/source/misc.cxx b/linguistic/source/misc.cxx
index 91c59b5..c273175 100644
--- a/linguistic/source/misc.cxx
+++ b/linguistic/source/misc.cxx
@@ -88,7 +88,7 @@ LanguageType LinguLocaleToLanguage( const ::com::sun::star::lang::Locale& rLocal
 {
     if ( rLocale.Language.isEmpty() )
         return LANGUAGE_NONE;
-    return LanguageTag( rLocale ).getLanguageType();
+    return LanguageTag::convertToLanguageType( rLocale );
 }
 
 
@@ -96,7 +96,7 @@ LanguageType LinguLocaleToLanguage( const ::com::sun::star::lang::Locale& rLocal
 {
     if (nLanguage == LANGUAGE_NONE)
         return ::com::sun::star::lang::Locale();
-    return LanguageTag( nLanguage).getLocale();
+    return LanguageTag::convertToLocale( nLanguage);
 }
 
 
diff --git a/linguistic/source/spelldsp.cxx b/linguistic/source/spelldsp.cxx
index a1d697e..9a1ebca 100644
--- a/linguistic/source/spelldsp.cxx
+++ b/linguistic/source/spelldsp.cxx
@@ -167,7 +167,7 @@ sal_Bool SvcListHasLanguage(
         if (pRef[k].is())
         {
             if (aTmpLocale.Language.isEmpty())
-                aTmpLocale = LanguageTag( nLanguage ).getLocale();
+                aTmpLocale = LanguageTag::convertToLocale( nLanguage );
             bHasLanguage = pRef[k]->hasLocale( aTmpLocale );
         }
     }
@@ -209,7 +209,7 @@ Sequence< Locale > SAL_CALL SpellCheckerDispatcher::getLocales()
     SpellSvcByLangMap_t::const_iterator aIt;
     for (aIt = aSvcMap.begin();  aIt != aSvcMap.end();  ++aIt)
     {
-        *pLocales++ = LanguageTag( aIt->first ).getLocale();
+        *pLocales++ = LanguageTag::convertToLocale( aIt->first );
     }
     return aLocales;
 }
@@ -299,7 +299,7 @@ sal_Bool SpellCheckerDispatcher::isValid_Impl(
     if (pEntry)
     {
         OUString aChkWord( rWord );
-        Locale aLocale( LanguageTag( nLanguage ).getLocale() );
+        Locale aLocale( LanguageTag::convertToLocale( nLanguage ) );
 
         // replace typographical apostroph by ascii apostroph
         String aSingleQuote( GetLocaleDataWrapper( nLanguage ).getQuotationMarkEnd() );
@@ -466,7 +466,7 @@ Reference< XSpellAlternatives > SpellCheckerDispatcher::spell_Impl(
     if (pEntry)
     {
         OUString aChkWord( rWord );
-        Locale aLocale( LanguageTag( nLanguage ).getLocale() );
+        Locale aLocale( LanguageTag::convertToLocale( nLanguage ) );
 
         // replace typographical apostroph by ascii apostroph
         String aSingleQuote( GetLocaleDataWrapper( nLanguage ).getQuotationMarkEnd() );
@@ -728,7 +728,7 @@ sal_Bool SAL_CALL SpellCheckerDispatcher::hasLanguage(
 throw (uno::RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return hasLocale( LanguageTag( nLanguage).getLocale() );
+    return hasLocale( LanguageTag::convertToLocale( nLanguage) );
 }
 
 
@@ -739,7 +739,7 @@ sal_Bool SAL_CALL SpellCheckerDispatcher::isValid(
 throw (lang::IllegalArgumentException, uno::RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return isValid( rWord, LanguageTag( nLanguage ).getLocale(), rProperties);
+    return isValid( rWord, LanguageTag::convertToLocale( nLanguage ), rProperties);
 }
 
 
@@ -750,7 +750,7 @@ uno::Reference< linguistic2::XSpellAlternatives > SAL_CALL SpellCheckerDispatche
 throw (lang::IllegalArgumentException, uno::RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return spell( rWord, LanguageTag( nLanguage).getLocale(), rProperties);
+    return spell( rWord, LanguageTag::convertToLocale( nLanguage), rProperties);
 }
 
 
diff --git a/linguistic/source/spelldta.cxx b/linguistic/source/spelldta.cxx
index 82178a3..80c40a0 100644
--- a/linguistic/source/spelldta.cxx
+++ b/linguistic/source/spelldta.cxx
@@ -212,7 +212,7 @@ Locale SAL_CALL SpellAlternatives::getLocale()
         throw(RuntimeException)
 {
     MutexGuard  aGuard( GetLinguMutex() );
-    return LanguageTag( nLanguage ).getLocale();
+    return LanguageTag::convertToLocale( nLanguage );
 }
 
 
diff --git a/linguistic/source/thesdsp.cxx b/linguistic/source/thesdsp.cxx
index c8d31ca..49dfc31 100644
--- a/linguistic/source/thesdsp.cxx
+++ b/linguistic/source/thesdsp.cxx
@@ -89,7 +89,7 @@ Sequence< Locale > SAL_CALL
     ThesSvcByLangMap_t::const_iterator aIt;
     for (aIt = aSvcMap.begin();  aIt != aSvcMap.end();  ++aIt)
     {
-        *pLocales++ = LanguageTag( aIt->first ).getLocale();
+        *pLocales++ = LanguageTag::convertToLocale( aIt->first );
     }
     return aLocales;
 }
diff --git a/oox/source/docprop/docprophandler.cxx b/oox/source/docprop/docprophandler.cxx
index 467151d..56242e1 100644
--- a/oox/source/docprop/docprophandler.cxx
+++ b/oox/source/docprop/docprophandler.cxx
@@ -409,7 +409,7 @@ void SAL_CALL OOXMLDocPropHandler::characters( const OUString& aChars )
 
                 case DC_TOKEN( language ):
                     if ( aChars.getLength() >= 2 )
-                        m_xDocProp->setLanguage( LanguageTag( aChars).getLocale() );
+                        m_xDocProp->setLanguage( LanguageTag::convertToLocale( aChars) );
                     break;
 
                 case COREPR_TOKEN( lastModifiedBy ):
diff --git a/reportdesign/source/core/api/ReportComponent.cxx b/reportdesign/source/core/api/ReportComponent.cxx
index 998aefb..758102a 100644
--- a/reportdesign/source/core/api/ReportComponent.cxx
+++ b/reportdesign/source/core/api/ReportComponent.cxx
@@ -84,11 +84,11 @@ OFormatProperties::OFormatProperties()
         using namespace ::com::sun::star::i18n::ScriptType;
 
         aLinguConfig.GetProperty(OUString("DefaultLocale")) >>= aCharLocale;
-        LanguageType eCurLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aCharLocale).getLanguageType(false), LATIN);
+        LanguageType eCurLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aCharLocale, false), LATIN);
         aLinguConfig.GetProperty(OUString("DefaultLocale_CJK"))  >>= aCharLocaleAsian;
-        LanguageType eCurLangCJK = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aCharLocaleAsian).getLanguageType(false), ASIAN);
+        LanguageType eCurLangCJK = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aCharLocaleAsian, false), ASIAN);
         aLinguConfig.GetProperty(OUString("DefaultLocale_CTL"))  >>= aCharLocaleComplex;
-        LanguageType eCurLangCTL = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aCharLocaleComplex).getLanguageType(false), COMPLEX);
+        LanguageType eCurLangCTL = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aCharLocaleComplex, false), COMPLEX);
 
         Font aLatin,aCJK,aCTL;
         lcl_getDefaultFonts(aLatin,aCJK,aCTL,eCurLang,eCurLangCJK,eCurLangCTL);
diff --git a/sc/source/core/tool/addincol.cxx b/sc/source/core/tool/addincol.cxx
index 20ab937..3cc1eef 100644
--- a/sc/source/core/tool/addincol.cxx
+++ b/sc/source/core/tool/addincol.cxx
@@ -114,7 +114,7 @@ const ::std::vector<ScUnoAddInFuncData::LocalizedName>& ScUnoAddInFuncData::GetC
                     for (sal_Int32 i=0; i<nSeqLen; i++)
                     {
                         maCompNames.push_back( LocalizedName(
-                                    LanguageTag( pArray[i].Locale).getBcp47( false),
+                                    LanguageTag::convertToBcp47( pArray[i].Locale, false),
                                     pArray[i].Name));
                     }
                 }
diff --git a/sc/source/filter/oox/numberformatsbuffer.cxx b/sc/source/filter/oox/numberformatsbuffer.cxx
index e6f3815..d6992f5 100644
--- a/sc/source/filter/oox/numberformatsbuffer.cxx
+++ b/sc/source/filter/oox/numberformatsbuffer.cxx
@@ -2023,7 +2023,7 @@ void NumberFormatsBuffer::insertBuiltinFormats()
         aBuiltinMap[ OUString::createFromAscii( pTable->mpcLocale ) ] = pTable;
 
     // convert locale string to locale struct
-    Locale aSysLocale( LanguageTag( maLocaleStr).getLocale());
+    Locale aSysLocale( LanguageTag::convertToLocale( maLocaleStr));
 
     // build a list of table pointers for the current locale, with all parent tables
     typedef ::std::vector< const BuiltinFormatTable* > BuiltinVec;
diff --git a/sc/source/ui/app/scmod2.cxx b/sc/source/ui/app/scmod2.cxx
index 0a02cc6..be7eccd 100644
--- a/sc/source/ui/app/scmod2.cxx
+++ b/sc/source/ui/app/scmod2.cxx
@@ -74,7 +74,7 @@ sal_Bool ScModule::HasThesaurusLanguage( sal_uInt16 nLang )
     {
         uno::Reference< linguistic2::XThesaurus > xThes(LinguMgr::GetThesaurus());
         if ( xThes.is() )
-            bHasLang = xThes->hasLocale( LanguageTag( nLang ).getLocale() );
+            bHasLang = xThes->hasLocale( LanguageTag::convertToLocale( nLang ) );
     }
     catch( uno::Exception& )
     {
diff --git a/sc/source/ui/dbgui/tpsort.cxx b/sc/source/ui/dbgui/tpsort.cxx
index 1479313..8ab5a74 100644
--- a/sc/source/ui/dbgui/tpsort.cxx
+++ b/sc/source/ui/dbgui/tpsort.cxx
@@ -695,7 +695,7 @@ void ScTabPageSortOptions::Reset( const SfxItemSet& /* rArgSet */ )
         m_pBtnHeader->SetText( aStrRowLabel );
     }
 
-    LanguageType eLang = LanguageTag( aSortData.aCollatorLocale ).getLanguageType( false);
+    LanguageType eLang = LanguageTag::convertToLanguageType( aSortData.aCollatorLocale, false);
     if ( eLang == LANGUAGE_DONTKNOW )
         eLang = LANGUAGE_SYSTEM;
     m_pLbLanguage->SelectLanguage( eLang );
@@ -762,7 +762,7 @@ sal_Bool ScTabPageSortOptions::FillItemSet( SfxItemSet& rArgSet )
 
     // get locale
     LanguageType eLang = m_pLbLanguage->GetSelectLanguage();
-    aNewSortData.aCollatorLocale = LanguageTag( eLang ).getLocale( false );
+    aNewSortData.aCollatorLocale = LanguageTag::convertToLocale( eLang, false);
 
     // get algorithm
     OUString sAlg;
@@ -989,7 +989,7 @@ IMPL_LINK_NOARG(ScTabPageSortOptions, FillAlgorHdl)
     }
     else
     {
-        lang::Locale aLocale( LanguageTag( eLang ).getLocale());
+        lang::Locale aLocale( LanguageTag::convertToLocale( eLang ));
         uno::Sequence<OUString> aAlgos = pColWrap->listCollatorAlgorithms( aLocale );
 
         long nCount = aAlgos.getLength();
diff --git a/sc/source/ui/docshell/docsh2.cxx b/sc/source/ui/docshell/docsh2.cxx
index f206a9d..79f1c10 100644
--- a/sc/source/ui/docshell/docsh2.cxx
+++ b/sc/source/ui/docshell/docsh2.cxx
@@ -130,7 +130,7 @@ void ScDocShell::InitItems()
                 {
                     i18n::ForbiddenCharacters aForbidden;
                     aAsian.GetStartEndChars( pLocales[i], aForbidden.beginLine, aForbidden.endLine );
-                    LanguageType eLang = LanguageTag(pLocales[i]).getLanguageType();
+                    LanguageType eLang = LanguageTag::convertToLanguageType(pLocales[i]);
 
                     xForbiddenTable->SetForbiddenCharacters( eLang, aForbidden );
                 }
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx
index 8629a03..a231205 100644
--- a/sc/source/ui/docshell/impex.cxx
+++ b/sc/source/ui/docshell/impex.cxx
@@ -1293,7 +1293,7 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm )
     aTransliteration.loadModuleIfNeeded( eDocLang );
     CalendarWrapper aCalendar( comphelper::getProcessComponentContext() );
     aCalendar.loadDefaultCalendar(
-        LanguageTag( eDocLang ).getLocale() );
+        LanguageTag::convertToLocale( eDocLang ) );
     boost::scoped_ptr< ::utl::TransliterationWrapper > pEnglishTransliteration;
     boost::scoped_ptr< CalendarWrapper > pEnglishCalendar;
     if ( eDocLang != LANGUAGE_ENGLISH_US )
@@ -1303,7 +1303,7 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm )
         aTransliteration.loadModuleIfNeeded( LANGUAGE_ENGLISH_US );
         pEnglishCalendar.reset(new CalendarWrapper ( comphelper::getProcessComponentContext() ));
         pEnglishCalendar->loadDefaultCalendar(
-            LanguageTag( LANGUAGE_ENGLISH_US ).getLocale() );
+            LanguageTag::convertToLocale( LANGUAGE_ENGLISH_US ) );
     }
 
     OUString aLine;
diff --git a/sc/source/ui/unoobj/convuno.cxx b/sc/source/ui/unoobj/convuno.cxx
index 4a30dbd..013ed06 100644
--- a/sc/source/ui/unoobj/convuno.cxx
+++ b/sc/source/ui/unoobj/convuno.cxx
@@ -34,7 +34,7 @@ LanguageType ScUnoConversion::GetLanguage( const lang::Locale& rLocale )
     if ( rLocale.Language.isEmpty() )
         return LANGUAGE_SYSTEM;
 
-    LanguageType eRet = LanguageTag( rLocale ).getLanguageType( false);
+    LanguageType eRet = LanguageTag::convertToLanguageType( rLocale, false);
     if ( eRet == LANGUAGE_NONE )
         eRet = LANGUAGE_SYSTEM;         //! or throw an exception?
 
@@ -43,7 +43,7 @@ LanguageType ScUnoConversion::GetLanguage( const lang::Locale& rLocale )
 
 void ScUnoConversion::FillLocale( lang::Locale& rLocale, LanguageType eLang )
 {
-    rLocale = LanguageTag( eLang ).getLocale();
+    rLocale = LanguageTag::convertToLocale( eLang );
 }
 
 
diff --git a/sc/source/ui/unoobj/defltuno.cxx b/sc/source/ui/unoobj/defltuno.cxx
index 992acca..ab2306d 100644
--- a/sc/source/ui/unoobj/defltuno.cxx
+++ b/sc/source/ui/unoobj/defltuno.cxx
@@ -183,7 +183,7 @@ void SAL_CALL ScDocDefaultsObj::setPropertyValue(
         {
             LanguageType eNew;
             if (!aLocale.Language.isEmpty() || !aLocale.Country.isEmpty())
-                eNew = LanguageTag( aLocale ).getLanguageType( false);
+                eNew = LanguageTag::convertToLanguageType( aLocale, false);
             else
                 eNew = LANGUAGE_NONE;
 
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 62c6d00..58a819f 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -1214,7 +1214,7 @@ void SAL_CALL SdXImpressDocument::setPropertyValue( const OUString& aPropertyNam
             if(!(aValue >>= aLocale))
                 throw lang::IllegalArgumentException();
 
-            mpDoc->SetLanguage( LanguageTag(aLocale).getLanguageType(), EE_CHAR_LANGUAGE );
+            mpDoc->SetLanguage( LanguageTag::convertToLanguageType(aLocale), EE_CHAR_LANGUAGE );
             break;
         }
         case WID_MODEL_TABSTOP:
@@ -1287,7 +1287,7 @@ uno::Any SAL_CALL SdXImpressDocument::getPropertyValue( const OUString& Property
         case WID_MODEL_LANGUAGE:
         {
             LanguageType eLang = mpDoc->GetLanguage( EE_CHAR_LANGUAGE );
-            aAny <<= LanguageTag( eLang).getLocale();
+            aAny <<= LanguageTag::convertToLocale( eLang);
             break;
         }
         case WID_MODEL_TABSTOP:
diff --git a/sd/source/ui/unoidl/unopool.cxx b/sd/source/ui/unoidl/unopool.cxx
index 983ce76..1c1157b 100644
--- a/sd/source/ui/unoidl/unopool.cxx
+++ b/sd/source/ui/unoidl/unopool.cxx
@@ -35,7 +35,7 @@ LanguageType SdUnoGetLanguage( const lang::Locale& rLocale )
     if ( rLocale.Language.getLength() == 0 )
         return LANGUAGE_SYSTEM;
 
-    LanguageType eRet = LanguageTag( rLocale ).getLanguageType( false);
+    LanguageType eRet = LanguageTag::convertToLanguageType( rLocale, false);
     if ( eRet == LANGUAGE_NONE )
         eRet = LANGUAGE_SYSTEM;         //! or throw an exception?
 
diff --git a/sd/source/ui/view/drviews7.cxx b/sd/source/ui/view/drviews7.cxx
index 5579fe3..c930230 100644
--- a/sd/source/ui/view/drviews7.cxx
+++ b/sd/source/ui/view/drviews7.cxx
@@ -574,7 +574,7 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
             LanguageType            eLang = GetDoc()->GetLanguage( EE_CHAR_LANGUAGE );
             Reference< XThesaurus > xThesaurus( LinguMgr::GetThesaurus() );
 
-            if (!xThesaurus.is() || eLang == LANGUAGE_NONE || !xThesaurus->hasLocale( LanguageTag( eLang).getLocale()) )
+            if (!xThesaurus.is() || eLang == LANGUAGE_NONE || !xThesaurus->hasLocale( LanguageTag::convertToLocale( eLang)) )
                 rSet.DisableItem( SID_THESAURUS );
         }
     }
diff --git a/sd/source/ui/view/outlnvsh.cxx b/sd/source/ui/view/outlnvsh.cxx
index fc6f30f..df93540 100644
--- a/sd/source/ui/view/outlnvsh.cxx
+++ b/sd/source/ui/view/outlnvsh.cxx
@@ -1059,7 +1059,7 @@ void OutlineViewShell::GetMenuState( SfxItemSet &rSet )
             LanguageType            eLang = GetDoc()->GetLanguage( EE_CHAR_LANGUAGE );
             Reference< XThesaurus > xThesaurus( LinguMgr::GetThesaurus() );
 
-            if (!xThesaurus.is() || eLang == LANGUAGE_NONE || !xThesaurus->hasLocale( LanguageTag( eLang).getLocale()))
+            if (!xThesaurus.is() || eLang == LANGUAGE_NONE || !xThesaurus->hasLocale( LanguageTag::convertToLocale( eLang)))
                 rSet.DisableItem( SID_THESAURUS );
         }
     }
diff --git a/sfx2/source/doc/SfxDocumentMetaData.cxx b/sfx2/source/doc/SfxDocumentMetaData.cxx
index f1e96c6..fe08d67 100644
--- a/sfx2/source/doc/SfxDocumentMetaData.cxx
+++ b/sfx2/source/doc/SfxDocumentMetaData.cxx
@@ -1524,7 +1524,7 @@ void SAL_CALL
 SfxDocumentMetaData::setLanguage(const css::lang::Locale & the_value)
         throw (css::uno::RuntimeException)
 {
-    OUString text( LanguageTag( the_value).getBcp47( false));
+    OUString text( LanguageTag::convertToBcp47( the_value, false));
     setMetaTextAndNotify("dc:language", text);
 }
 
diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx
index 78d8ac2..136acac 100644
--- a/sfx2/source/doc/doctemplates.cxx
+++ b/sfx2/source/doc/doctemplates.cxx
@@ -401,7 +401,7 @@ void SfxDocTplService_Impl::init_Impl()
         getDefaultLocale();
 
     // convert locale to string
-    OUString aLang = LanguageTag( maLocale).getBcp47();
+    OUString aLang = LanguageTag::convertToBcp47( maLocale);
 
     // set maRootContent to the root of the templates hierarchy. Create the
     // entry if necessary
diff --git a/sfx2/source/menu/thessubmenu.cxx b/sfx2/source/menu/thessubmenu.cxx
index 3c22420..7c56a19 100644
--- a/sfx2/source/menu/thessubmenu.cxx
+++ b/sfx2/source/menu/thessubmenu.cxx
@@ -53,7 +53,7 @@ void SfxThesSubMenuHelper::GetLocale(
     xub_StrLen nDelimPos  )
 {
     String aIsoLang( rLookUpString.Copy( nDelimPos + 1) );
-    rLocale = LanguageTag( aIsoLang).getLocale();
+    rLocale = LanguageTag::convertToLocale( aIsoLang);
 }
 
 
diff --git a/starmath/source/parse.cxx b/starmath/source/parse.cxx
index aa3a66f..169ce5f 100644
--- a/starmath/source/parse.cxx
+++ b/starmath/source/parse.cxx
@@ -2467,7 +2467,7 @@ void SmParser::Error(SmParseError eError)
 
 
 SmParser::SmParser()
-    : m_aDotLoc( LanguageTag( LANGUAGE_ENGLISH_US ).getLocale() )
+    : m_aDotLoc( LanguageTag::convertToLocale( LANGUAGE_ENGLISH_US ) )
 {
     m_eConversion = CONVERT_NONE;
     bImportSymNames = m_bExportSymNames = false;
diff --git a/svl/source/config/asiancfg.cxx b/svl/source/config/asiancfg.cxx
index 695f762..b644705 100644
--- a/svl/source/config/asiancfg.cxx
+++ b/svl/source/config/asiancfg.cxx
@@ -50,7 +50,7 @@ OUString toString(css::lang::Locale const & locale) {
             "Locale language \"" << locale.Language << "\" contains \"-\"");
     SAL_WARN_IF( locale.Country.indexOf('-') != -1, "svl",
             "Locale country \"" << locale.Country << "\" contains \"-\"");
-    return LanguageTag( locale).getBcp47( false);
+    return LanguageTag::convertToBcp47( locale, false);
 }
 
 }
@@ -105,7 +105,7 @@ css::uno::Sequence< css::lang::Locale > SvxAsianConfig::GetStartEndCharLocales()
         getElementNames());
     css::uno::Sequence< css::lang::Locale > ls(ns.getLength());
     for (sal_Int32 i = 0; i < ns.getLength(); ++i) {
-        ls[i] = LanguageTag( ns[i]).getLocale( false);
+        ls[i] = LanguageTag::convertToLocale( ns[i], false);
     }
     return ls;
 }
diff --git a/svl/source/config/languageoptions.cxx b/svl/source/config/languageoptions.cxx
index a095ac5..687c99a 100644
--- a/svl/source/config/languageoptions.cxx
+++ b/svl/source/config/languageoptions.cxx
@@ -204,7 +204,7 @@ LanguageType SvtSystemLanguageOptions::GetWin16SystemLanguage() const
 {
     if( m_sWin16SystemLocale.isEmpty() )
         return LANGUAGE_NONE;
-    return LanguageTag( m_sWin16SystemLocale ).getLanguageType();
+    return LanguageTag::convertToLanguageType( m_sWin16SystemLocale );
 }
 
 bool SvtSystemLanguageOptions::isKeyboardLayoutTypeInstalled(sal_Int16 scriptType) const
diff --git a/svl/source/items/srchitem.cxx b/svl/source/items/srchitem.cxx
index c3ad82c..a75f83c 100644
--- a/svl/source/items/srchitem.cxx
+++ b/svl/source/items/srchitem.cxx
@@ -432,7 +432,7 @@ bool SvxSearchItem::QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMembe
         {
             sal_Int16 nLocale;
             if (!aSearchOpt.Locale.Language.isEmpty() || !aSearchOpt.Locale.Country.isEmpty() )
-                nLocale = LanguageTag( aSearchOpt.Locale ).getLanguageType();
+                nLocale = LanguageTag::convertToLanguageType( aSearchOpt.Locale );
             else
                 nLocale = LANGUAGE_NONE;
             rVal <<= nLocale;
@@ -581,7 +581,7 @@ bool SvxSearchItem::PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nM
                 }
                 else
                 {
-                    aSearchOpt.Locale = LanguageTag( nInt).getLocale();
+                    aSearchOpt.Locale = LanguageTag::convertToLocale( nInt);
                 }
             }
             break;
diff --git a/svl/source/numbers/numfmuno.cxx b/svl/source/numbers/numfmuno.cxx
index 95b012e..317abfa 100644
--- a/svl/source/numbers/numfmuno.cxx
+++ b/svl/source/numbers/numfmuno.cxx
@@ -101,7 +101,7 @@ static LanguageType lcl_GetLanguage( const lang::Locale& rLocale )
     if ( rLocale.Language.isEmpty() )
         return LANGUAGE_SYSTEM;
 
-    LanguageType eRet = LanguageTag( rLocale ).getLanguageType( false );
+    LanguageType eRet = LanguageTag::convertToLanguageType( rLocale, false);
     if ( eRet == LANGUAGE_NONE )
         eRet = LANGUAGE_SYSTEM; //! or throw an exception?
 
diff --git a/svl/source/numbers/supservs.cxx b/svl/source/numbers/supservs.cxx
index 198c5f6..70cce53 100644
--- a/svl/source/numbers/supservs.cxx
+++ b/svl/source/numbers/supservs.cxx
@@ -96,7 +96,7 @@ void SAL_CALL SvNumberFormatsSupplierServiceObject::initialize( const Sequence<
         {
             Locale aLocale;
             *pArgs >>= aLocale;
-            eNewFormatterLanguage = LanguageTag( aLocale).getLanguageType( false);
+            eNewFormatterLanguage = LanguageTag::convertToLanguageType( aLocale, false);
         }
 #ifdef DBG_UTIL
         else
diff --git a/svl/source/numbers/zforlist.cxx b/svl/source/numbers/zforlist.cxx
index f75748b..00a9a35 100644
--- a/svl/source/numbers/zforlist.cxx
+++ b/svl/source/numbers/zforlist.cxx
@@ -3704,7 +3704,7 @@ void SvNumberFormatter::ImpInitCurrencyTable()
     sal_uInt16 nLegacyOnlyCurrencyPos = 0;
     for ( sal_Int32 nLocale = 0; nLocale < nLocaleCount; nLocale++ )
     {
-        LanguageType eLang = LanguageTag( pLocales[nLocale]).getLanguageType( false);
+        LanguageType eLang = LanguageTag::convertToLanguageType( pLocales[nLocale], false);
         rInstalledLocales.insert( eLang);
         pLocaleData->setLanguageTag( LanguageTag( pLocales[nLocale]) );
         Sequence< Currency2 > aCurrSeq = pLocaleData->getAllCurrencies();
diff --git a/svtools/langsupport/langsupport.cxx b/svtools/langsupport/langsupport.cxx
index 226187a..12269ca 100644
--- a/svtools/langsupport/langsupport.cxx
+++ b/svtools/langsupport/langsupport.cxx
@@ -56,7 +56,7 @@ SAL_IMPLEMENT_MAIN()
                 continue;
             }
 
-            OUString sTag( LanguageTag( eLang).getBcp47());
+            OUString sTag( LanguageTag::convertToBcp47( eLang));
 
             std::cout << OUStringToOString(sTag, osl_getThreadTextEncoding()).getStr()
                 << std::endl;
diff --git a/svtools/source/misc/langtab.cxx b/svtools/source/misc/langtab.cxx
index b83443d..4fcaa73 100644
--- a/svtools/source/misc/langtab.cxx
+++ b/svtools/source/misc/langtab.cxx
@@ -143,7 +143,7 @@ const OUString SvtLanguageTable::GetString( const LanguageType eType, bool bUser
         return ResStringArray::GetString( nPos );
 
     //Rather than return a fairly useless "Unknown" name, return a geeky but usable-in-a-pinch lang-tag
-    OUString sLangTag(LanguageTag(eType).getBcp47());
+    OUString sLangTag(LanguageTag::convertToBcp47(eType));
     SAL_WARN("svtools.misc", "Language: 0x"
         << std::hex << eType
         << " with unknown name, so returning lang-tag of: "
diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx
index 7291b17..093f128 100644
--- a/svx/source/dialog/langbox.cxx
+++ b/svx/source/dialog/langbox.cxx
@@ -80,7 +80,7 @@ static Sequence< sal_Int16 > lcl_LocaleSeqToLangSeq( Sequence< Locale > &rSeq )
     sal_Int16 *pLang = aLangs.getArray();
     for (sal_Int32 i = 0;  i < nCount;  ++i)
     {
-        pLang[i] = LanguageTag( pLocale[i] ).getLanguageType();
+        pLang[i] = LanguageTag::convertToLanguageType( pLocale[i] );
 
     }
 
diff --git a/svx/source/form/fmcontrollayout.cxx b/svx/source/form/fmcontrollayout.cxx
index 204338e..dc930f2 100644
--- a/svx/source/form/fmcontrollayout.cxx
+++ b/svx/source/form/fmcontrollayout.cxx
@@ -176,7 +176,7 @@ namespace svxform
                 }
 
                 // retrieve a default font for this locale, and set it at the control
-                Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS, LanguageTag( aDocumentCharLocale ).getLanguageType(), DEFAULTFONT_FLAGS_ONLYONE );
+                Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS, LanguageTag::convertToLanguageType( aDocumentCharLocale ), DEFAULTFONT_FLAGS_ONLYONE );
                 FontDescriptor aFontDesc = VCLUnoHelper::CreateFontDescriptor( aFont );
                 _rxModel->setPropertyValue(
                     OUString( "FontDescriptor" ),
diff --git a/sw/source/core/bastyp/init.cxx b/sw/source/core/bastyp/init.cxx
index e6af8f9..009600c 100644
--- a/sw/source/core/bastyp/init.cxx
+++ b/sw/source/core/bastyp/init.cxx
@@ -816,7 +816,7 @@ void SwCalendarWrapper::LoadDefaultCalendar( sal_uInt16 eLang )
 {
     sUniqueId.Erase();
     if( eLang != nLang )
-        loadDefaultCalendar( LanguageTag( nLang = eLang ).getLocale());
+        loadDefaultCalendar( LanguageTag::convertToLocale( nLang = eLang ));
 }
 
 LanguageType GetAppLanguage()
diff --git a/sw/source/core/doc/docsort.cxx b/sw/source/core/doc/docsort.cxx
index ab89350..615ff30 100644
--- a/sw/source/core/doc/docsort.cxx
+++ b/sw/source/core/doc/docsort.cxx
@@ -82,7 +82,7 @@ void SwSortElement::Init( SwDoc* pD, const SwSortOptions& rOpt,
         nLang = GetAppLanguage();
         break;
     }
-    pLocale = new lang::Locale( LanguageTag( nLang ).getLocale() );
+    pLocale = new lang::Locale( LanguageTag::convertToLocale( nLang ) );
 
     pSortCollator = new CollatorWrapper( ::comphelper::getProcessComponentContext() );
 }
diff --git a/sw/source/core/fields/authfld.cxx b/sw/source/core/fields/authfld.cxx
index fb2e3b3..d1fbe79 100644
--- a/sw/source/core/fields/authfld.cxx
+++ b/sw/source/core/fields/authfld.cxx
@@ -445,7 +445,7 @@ bool    SwAuthorityFieldType::PutValue( const Any& rAny, sal_uInt16 nWhichId )
         {
             com::sun::star::lang::Locale aLocale;
             if( 0 != (bRet = rAny >>= aLocale ))
-                SetLanguage( LanguageTag( aLocale ).getLanguageType());
+                SetLanguage( LanguageTag::convertToLanguageType( aLocale ));
         }
         break;
 
diff --git a/sw/source/core/tox/txmsrt.cxx b/sw/source/core/tox/txmsrt.cxx
index 22e7091..20e4975 100644
--- a/sw/source/core/tox/txmsrt.cxx
+++ b/sw/source/core/tox/txmsrt.cxx
@@ -75,7 +75,7 @@ void SwTOXInternational::Init()
 {
     pIndexWrapper = new IndexEntrySupplierWrapper();
 
-    const lang::Locale aLcl( LanguageTag( eLang ).getLocale() );
+    const lang::Locale aLcl( LanguageTag::convertToLocale( eLang ) );
     pIndexWrapper->SetLocale( aLcl );
 
     if(!sSortAlgorithm.Len())
diff --git a/sw/source/core/unocore/unoflatpara.cxx b/sw/source/core/unocore/unoflatpara.cxx
index c1c2b92..1f17df3 100644
--- a/sw/source/core/unocore/unoflatpara.cxx
+++ b/sw/source/core/unocore/unoflatpara.cxx
@@ -191,7 +191,7 @@ lang::Locale SAL_CALL SwXFlatParagraph::getLanguageOfText(::sal_Int32 nPos, ::sa
 {
     SolarMutexGuard aGuard;
     if (!mpTxtNode)
-        return LanguageTag( LANGUAGE_NONE ).getLocale();
+        return LanguageTag::convertToLocale( LANGUAGE_NONE );
 
     const lang::Locale aLocale( SW_BREAKITER()->GetLocale( mpTxtNode->GetLang( static_cast<sal_uInt16>(nPos), static_cast<sal_uInt16>(nLen) ) ) );
     return aLocale;
@@ -204,7 +204,7 @@ lang::Locale SAL_CALL SwXFlatParagraph::getPrimaryLanguageOfText(::sal_Int32 nPo
     SolarMutexGuard aGuard;
 
     if (!mpTxtNode)
-        return LanguageTag( LANGUAGE_NONE ).getLocale();
+        return LanguageTag::convertToLocale( LANGUAGE_NONE );
 
     const lang::Locale aLocale( SW_BREAKITER()->GetLocale( mpTxtNode->GetLang( static_cast<sal_uInt16>(nPos), static_cast<sal_uInt16>(nLen) ) ) );
     return aLocale;
diff --git a/sw/source/core/unocore/unoidx.cxx b/sw/source/core/unocore/unoidx.cxx
index cda70a1..411f5cc 100644
--- a/sw/source/core/unocore/unoidx.cxx
+++ b/sw/source/core/unocore/unoidx.cxx
@@ -638,7 +638,7 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException,
             {
                 throw lang::IllegalArgumentException();
             }
-            rTOXBase.SetLanguage( LanguageTag(aLocale).getLanguageType());
+            rTOXBase.SetLanguage( LanguageTag::convertToLanguageType(aLocale));
         }
         break;
         case WID_IDX_SORT_ALGORITHM:
diff --git a/sw/source/core/unocore/unoobj.cxx b/sw/source/core/unocore/unoobj.cxx
index e03ad27..f4ac2b6 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -2808,7 +2808,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties(
             lang::Locale aLocale;
             if (aValue >>= aLocale)
             {
-                rSortOpt.nLanguage = LanguageTag( aLocale).getLanguageType();
+                rSortOpt.nLanguage = LanguageTag::convertToLanguageType( aLocale);
             }
             else
             {
@@ -2917,7 +2917,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties(
                     {
                         rSortOpt.bIgnoreCase = !pFields[i].IsCaseSensitive;
                         rSortOpt.nLanguage =
-                            LanguageTag( pFields[i].CollatorLocale ).getLanguageType();
+                            LanguageTag::convertToLanguageType( pFields[i].CollatorLocale );
                         aKeys[i]->sSortType = pFields[i].CollatorAlgorithm;
                         aKeys[i]->nColumnId =
                             static_cast<sal_uInt16>(pFields[i].Field);
diff --git a/sw/source/filter/basflt/fltini.cxx b/sw/source/filter/basflt/fltini.cxx
index 6dccc83..963156e 100644
--- a/sw/source/filter/basflt/fltini.cxx
+++ b/sw/source/filter/basflt/fltini.cxx
@@ -623,7 +623,7 @@ void SwAsciiOptions::ReadUserData( const String& rStr )
                                 sFont = sToken;
                                 break;
                         case 3:         // Language
-                nLanguage = LanguageTag( sToken ).getLanguageType();
+                nLanguage = LanguageTag::convertToLanguageType( sToken );
                                 break;
                         }
                 }
@@ -659,7 +659,7 @@ void SwAsciiOptions::WriteUserData( String& rStr )
         // 4. Language
         if (nLanguage)
         {
-        OUString sTmp = LanguageTag( nLanguage ).getBcp47();
+        OUString sTmp = LanguageTag::convertToBcp47( nLanguage );
         rStr += (String)sTmp;
         }
         rStr += ',';
diff --git a/sw/source/filter/html/css1atr.cxx b/sw/source/filter/html/css1atr.cxx
index effb4a8..155eaa6 100644
--- a/sw/source/filter/html/css1atr.cxx
+++ b/sw/source/filter/html/css1atr.cxx
@@ -2754,7 +2754,7 @@ static Writer& OutCSS1_SvxLanguage( Writer& rWrt, const SfxPoolItem& rHt )
     if( LANGUAGE_DONTKNOW == eLang )
         return rWrt;
 
-    String sOut = LanguageTag( eLang ).getBcp47();
+    String sOut = LanguageTag::convertToBcp47( eLang );
 
     rHTMLWrt.OutCSS1_Property( sCSS1_P_so_language, sOut );
 
diff --git a/sw/source/filter/html/htmlcss1.cxx b/sw/source/filter/html/htmlcss1.cxx
index 6423ce5..3ac6243 100644
--- a/sw/source/filter/html/htmlcss1.cxx
+++ b/sw/source/filter/html/htmlcss1.cxx
@@ -1942,7 +1942,7 @@ sal_Bool SwHTMLParser::ParseStyleOptions( const String &rStyle,
 
     if( pLang && pLang->Len() )
     {
-        LanguageType eLang = LanguageTag( *pLang ).getLanguageType();
+        LanguageType eLang = LanguageTag::convertToLanguageType( *pLang );
         if( LANGUAGE_DONTKNOW != eLang )
         {
             SvxLanguageItem aLang( eLang, RES_CHRATR_LANGUAGE );
diff --git a/sw/source/filter/html/htmlgrin.cxx b/sw/source/filter/html/htmlgrin.cxx
index de89a59..aa4a933 100644
--- a/sw/source/filter/html/htmlgrin.cxx
+++ b/sw/source/filter/html/htmlgrin.cxx
@@ -987,7 +987,7 @@ void SwHTMLParser::InsertBodyOptions()
     }
     if( aLang.Len() )
     {
-        LanguageType eLang = LanguageTag( aLang ).getLanguageType();
+        LanguageType eLang = LanguageTag::convertToLanguageType( aLang );
         if( LANGUAGE_DONTKNOW != eLang )
         {
             sal_uInt16 nWhich = 0;
diff --git a/sw/source/filter/html/wrthtml.cxx b/sw/source/filter/html/wrthtml.cxx
index 124e79f..5df779f 100644
--- a/sw/source/filter/html/wrthtml.cxx
+++ b/sw/source/filter/html/wrthtml.cxx
@@ -1180,7 +1180,7 @@ void SwHTMLWriter::OutLanguage( LanguageType nLang )
         sOut.append(' ').append(OOO_STRING_SVTOOLS_HTML_O_lang)
             .append("=\"");
         Strm() << sOut.makeStringAndClear().getStr();
-        HTMLOutFuncs::Out_String( Strm(), LanguageTag(nLang).getBcp47(),
+        HTMLOutFuncs::Out_String( Strm(), LanguageTag::convertToBcp47(nLang),
                                   eDestEnc, &aNonConvertableCharacters ) << '"';
     }
 }
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index d7697ca..1c0e257 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -1199,7 +1199,7 @@ void DocxAttributeOutput::StartRuby( const SwTxtNode& rNode, xub_StrLen nPos, co
     // lid
     lang::Locale aLocale( SwBreakIt::Get()->GetLocale(
                 rNode.GetLang( nPos ) ) );
-    OUString sLang( LanguageTag( aLocale).getBcp47() );
+    OUString sLang( LanguageTag::convertToBcp47( aLocale) );
     m_pSerializer->singleElementNS( XML_w, XML_lid,
             FSNS( XML_w, XML_val ),
             OUStringToOString( sLang, RTL_TEXTENCODING_UTF8 ).getStr( ), FSEND );
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 32dc410..ce231d6 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -2424,7 +2424,7 @@ CharSet SwWW8ImplReader::GetCurrentCharSet()
             */
             const SvxLanguageItem *pLang = (const SvxLanguageItem*)GetFmtAttr(RES_CHRATR_LANGUAGE);
             LanguageType eLang = pLang ? pLang->GetLanguage() : LANGUAGE_SYSTEM;
-            ::com::sun::star::lang::Locale aLocale(LanguageTag(eLang).getLocale());
+            ::com::sun::star::lang::Locale aLocale(LanguageTag::convertToLocale(eLang));
             eSrcCharSet = msfilter::util::getBestTextEncodingFromLocale(aLocale);
         }
     }
diff --git a/sw/source/ui/app/appopt.cxx b/sw/source/ui/app/appopt.cxx
index 4cb564c..b3fb4af 100644
--- a/sw/source/ui/app/appopt.cxx
+++ b/sw/source/ui/app/appopt.cxx
@@ -154,17 +154,17 @@ SfxItemSet*  SwModule::CreateItemSet( sal_uInt16 nId )
 
         Any aLang = aLinguCfg.GetProperty(OUString("DefaultLocale"));
         aLang >>= aLocale;
-        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aLocale).getLanguageType(false), LATIN);
+        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aLocale, false), LATIN);
         pRet->Put(SvxLanguageItem(nLang, SID_ATTR_LANGUAGE));
 
         aLang = aLinguCfg.GetProperty(OUString("DefaultLocale_CJK"));
         aLang >>= aLocale;
-        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aLocale).getLanguageType(false), ASIAN);
+        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aLocale, false), ASIAN);
         pRet->Put(SvxLanguageItem(nLang, SID_ATTR_CHAR_CJK_LANGUAGE));
 
         aLang = aLinguCfg.GetProperty(OUString("DefaultLocale_CTL"));
         aLang >>= aLocale;
-        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aLocale).getLanguageType(false), COMPLEX);
+        nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aLocale, false), COMPLEX);
         pRet->Put(SvxLanguageItem(nLang, SID_ATTR_CHAR_CTL_LANGUAGE));
     }
     if(bTextDialog)
diff --git a/sw/source/ui/app/docshini.cxx b/sw/source/ui/app/docshini.cxx
index 58d77b9..5b37389 100644
--- a/sw/source/ui/app/docshini.cxx
+++ b/sw/source/ui/app/docshini.cxx
@@ -121,7 +121,7 @@ sal_Bool SwDocShell::InitNew( const uno::Reference < embed::XStorage >& xStor )
             {
                 ForbiddenCharacters aForbidden;
                 aAsian.GetStartEndChars( pLocales[i], aForbidden.beginLine, aForbidden.endLine);
-                LanguageType  eLang = LanguageTag(pLocales[i]).getLanguageType();
+                LanguageType  eLang = LanguageTag::convertToLanguageType(pLocales[i]);
                 pDoc->setForbiddenCharacters( eLang, aForbidden);
             }
         }
diff --git a/sw/source/ui/dbui/dbinsdlg.cxx b/sw/source/ui/dbui/dbinsdlg.cxx
index a237b50..d43b132 100644
--- a/sw/source/ui/dbui/dbinsdlg.cxx
+++ b/sw/source/ui/dbui/dbinsdlg.cxx
@@ -1670,7 +1670,7 @@ void SwInsertDBColAutoPilot::Commit()
 
         if( eLang != ePrevLang )
         {
-            sPrevLang = LanguageTag( eLang ).getBcp47();
+            sPrevLang = LanguageTag::convertToBcp47( eLang );
             ePrevLang = eLang;
         }
 
@@ -1761,7 +1761,7 @@ void SwInsertDBColAutoPilot::Load()
                  * case-insensitive equal language/country combos that may have
                  * worked, for all others not. FIXME if you need to read old
                  * data that you were never able to read before. */
-                pInsDBColumn->eUsrNumFmtLng = LanguageTag( sNumberFormatLocale ).getLanguageType();
+                pInsDBColumn->eUsrNumFmtLng = LanguageTag::convertToLanguageType( sNumberFormatLocale );
 
                 pInsDBColumn->nUsrNumFmt = rNFmtr.GetEntryKey( pInsDBColumn->sUsrNumFmt,
                                                         pInsDBColumn->eUsrNumFmtLng );
diff --git a/sw/source/ui/index/swuiidxmrk.cxx b/sw/source/ui/index/swuiidxmrk.cxx
index e9cf706..cab0acc 100644
--- a/sw/source/ui/index/swuiidxmrk.cxx
+++ b/sw/source/ui/index/swuiidxmrk.cxx
@@ -346,7 +346,7 @@ String  SwIndexMarkPane::GetDefaultPhoneticReading( const String& rText )
     if( !bIsPhoneticReadingEnabled )
         return aEmptyStr;
 
-    return xExtendedIndexEntrySupplier->getPhoneticCandidate(rText, LanguageTag( nLangForPhoneticReading ).getLocale());
+    return xExtendedIndexEntrySupplier->getPhoneticCandidate(rText, LanguageTag::convertToLocale( nLangForPhoneticReading ));
 }
 
 /* --------------------------------------------------
diff --git a/sw/source/ui/lingu/hhcwrp.cxx b/sw/source/ui/lingu/hhcwrp.cxx
index 5867e12..faa5e66 100644
--- a/sw/source/ui/lingu/hhcwrp.cxx

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list