[Libreoffice-commits] .: chart2/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Fri Nov 16 17:28:38 PST 2012
chart2/source/tools/CharacterProperties.cxx | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
New commits:
commit feec7a873ff803f7815c2d85adc7143a89f203d6
Author: Eike Rathke <erack at redhat.com>
Date: Sat Nov 17 02:28:07 2012 +0100
use LanguageTag
Change-Id: I3057ceee83c8ac3e88d0358f3de44d36fb1cde6f
diff --git a/chart2/source/tools/CharacterProperties.cxx b/chart2/source/tools/CharacterProperties.cxx
index 23bbdd2..029b071 100644
--- a/chart2/source/tools/CharacterProperties.cxx
+++ b/chart2/source/tools/CharacterProperties.cxx
@@ -45,6 +45,7 @@
// header for struct SvtLinguConfig
#include <unotools/lingucfg.hxx>
#include <i18npool/mslangid.hxx>
+#include <i18npool/languagetag.hxx>
#include <vcl/outdev.hxx>
using namespace ::com::sun::star;
@@ -409,11 +410,11 @@ void CharacterProperties::AddDefaultsToMap(
using namespace ::com::sun::star::i18n::ScriptType;
LanguageType nLang;
- nLang = MsLangId::resolveSystemLanguageByScriptType(MsLangId::convertLocaleToLanguage(aDefaultLocale), LATIN);
+ nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag(aDefaultLocale).getLanguageType( false), LATIN);
Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_LATIN_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
- nLang = MsLangId::resolveSystemLanguageByScriptType(MsLangId::convertLocaleToLanguage( aDefaultLocale_CJK), ASIAN);
+ nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag( aDefaultLocale_CJK).getLanguageType( false), ASIAN);
Font aFontCJK = OutputDevice::GetDefaultFont( DEFAULTFONT_CJK_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
- nLang = MsLangId::resolveSystemLanguageByScriptType(MsLangId::convertLocaleToLanguage( aDefaultLocale_CTL), COMPLEX);
+ nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag( aDefaultLocale_CTL).getLanguageType( 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() ) );
More information about the Libreoffice-commits
mailing list