summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2012-11-17 02:00:31 +0100
committerEike Rathke <erack@redhat.com>2012-11-17 02:00:39 +0100
commit2b0a014dce8bf811d82fdfb3c287a6e9dfab95de (patch)
tree1d0a43adb23f571c224b489e6efb7e9916cdeb2b /svx
parentcd52a285c183db9da7a2e40a0c314f6258f1d7af (diff)
use LanguageTag
Change-Id: Ibe18dc1b768c928e8f53ff4bf98adab40d808025
Diffstat (limited to 'svx')
-rw-r--r--svx/source/form/fmcontrollayout.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/form/fmcontrollayout.cxx b/svx/source/form/fmcontrollayout.cxx
index f441deef1873..06e34f9bc0d0 100644
--- a/svx/source/form/fmcontrollayout.cxx
+++ b/svx/source/form/fmcontrollayout.cxx
@@ -41,6 +41,7 @@
#include <comphelper/processfactory.hxx>
#include <i18npool/mslangid.hxx>
+#include <i18npool/languagetag.hxx>
#include <unotools/syslocale.hxx>
#include <toolkit/helper/vclunohelper.hxx>
@@ -142,7 +143,7 @@ namespace svxform
// determine the script type associated with the system locale
const SvtSysLocale aSysLocale;
const LocaleDataWrapper& rSysLocaleData = aSysLocale.GetLocaleData();
- const sal_Int16 eSysLocaleScriptType = MsLangId::getScriptType( MsLangId::convertLocaleToLanguage( rSysLocaleData.getLocale() ) );
+ const sal_Int16 eSysLocaleScriptType = MsLangId::getScriptType( LanguageTag( rSysLocaleData.getLocale() ).getLanguageType() );
// depending on this script type, use the right property from the document's style which controls the
// default locale for document content
@@ -185,7 +186,7 @@ namespace svxform
}
// retrieve a default font for this locale, and set it at the control
- Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS, MsLangId::convertLocaleToLanguage( aDocumentCharLocale ), DEFAULTFONT_FLAGS_ONLYONE );
+ Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS, LanguageTag( aDocumentCharLocale ).getLanguageType(), DEFAULTFONT_FLAGS_ONLYONE );
FontDescriptor aFontDesc = VCLUnoHelper::CreateFontDescriptor( aFont );
_rxModel->setPropertyValue(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FontDescriptor" ) ),