[Libreoffice-commits] core.git: vcl/win
Caolán McNamara
caolanm at redhat.com
Mon Oct 21 06:39:18 PDT 2013
vcl/win/source/gdi/salgdi3.cxx | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
New commits:
commit 678b260c30ffd06d6c5ae94d81e5d9f738c2b8a7
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Oct 21 14:38:42 2013 +0100
some windows only Strings
Change-Id: I264bdfc3453e2b6a17397ffb27154a29394c8c1b
diff --git a/vcl/win/source/gdi/salgdi3.cxx b/vcl/win/source/gdi/salgdi3.cxx
index a9efe50..7bbb009 100644
--- a/vcl/win/source/gdi/salgdi3.cxx
+++ b/vcl/win/source/gdi/salgdi3.cxx
@@ -613,7 +613,7 @@ struct ImplEnumInfo
// =======================================================================
-static CharSet ImplCharSetToSal( BYTE nCharSet )
+static rtl_TextEncoding ImplCharSetToSal( BYTE nCharSet )
{
rtl_TextEncoding eTextEncoding;
@@ -2060,8 +2060,10 @@ static bool ImplGetFontAttrFromFile( const String& rFontFileURL,
return false;
// convert byte strings to unicode
- rDFA.SetFamilyName(String( aBuffer + nNameOfs, osl_getThreadTextEncoding() ));
- rDFA.SetStyleName(String( aBuffer + nStyleOfs, osl_getThreadTextEncoding() ));
+ char *pName = aBuffer + nNameOfs;
+ rDFA.SetFamilyName(OUString(pName, strlen(pName), osl_getThreadTextEncoding()));
+ char *pStyle = aBuffer + nStyleOfs;
+ rDFA.SetStyleName(OUString(pStyle, strlen(pStyle), osl_getThreadTextEncoding() ));
// byte offset 0x4C7: OS2_fsSelection
const char nFSS = aBuffer[ 0x4C7 ];
@@ -2181,12 +2183,12 @@ void WinSalGraphics::GetDevFontList( ImplDevFontList* pFontList )
String aEmptyString;
OUString aBootStrap;
- rtl::Bootstrap::get( String( RTL_CONSTASCII_USTRINGPARAM( "BRAND_BASE_DIR" ) ), aBootStrap );
- aBootStrap += String( RTL_CONSTASCII_USTRINGPARAM( "/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE( "bootstrap" ) ) );
+ rtl::Bootstrap::get( OUString("BRAND_BASE_DIR"), aBootStrap );
+ aBootStrap += OUString("/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE( "bootstrap" ) );
rtl::Bootstrap aBootstrap( aBootStrap );
OUString aUserPath;
aBootstrap.getFrom( OUString( "UserInstallation" ), aUserPath );
- aUserPath += String( RTL_CONSTASCII_USTRINGPARAM("/user/config/fontnames.dat") );
+ aUserPath += "/user/config/fontnames.dat";
String aBaseURL = aPath.copy( 0, aPath.lastIndexOf('/')+1 );
mpFontAttrCache = new ImplFontAttrCache( aUserPath, aBaseURL );
More information about the Libreoffice-commits
mailing list