diff options
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/font/font.cxx | 2 | ||||
-rw-r--r-- | vcl/win/gdi/salfont.cxx | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/vcl/source/font/font.cxx b/vcl/source/font/font.cxx index cc24f06f33eb..046816510087 100644 --- a/vcl/source/font/font.cxx +++ b/vcl/source/font/font.cxx @@ -464,7 +464,7 @@ namespace GetTTGlobalFontInfo( pTTF, &aInfo ); // most importantly: the family name if( aInfo.ufamily ) - o_rResult.SetFamilyName( aInfo.ufamily ); + o_rResult.SetFamilyName( OUString(aInfo.ufamily) ); else if( aInfo.family ) o_rResult.SetFamilyName( OStringToOUString( aInfo.family, RTL_TEXTENCODING_ASCII_US ) ); // set weight diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx index be55c9df0b40..4dac58aaafb2 100644 --- a/vcl/win/gdi/salfont.cxx +++ b/vcl/win/gdi/salfont.cxx @@ -548,7 +548,7 @@ static FontAttributes WinFont2DevFontAttributes( const ENUMLOGFONTEXW& rEnumFont aDFA.SetSymbolFlag(rLogFont.lfCharSet == SYMBOL_CHARSET); // get the font face name - aDFA.SetFamilyName(o3tl::toU(rLogFont.lfFaceName)); + aDFA.SetFamilyName(OUString(o3tl::toU(rLogFont.lfFaceName))); // use the face's style name only if it looks reasonable const wchar_t* pStyleName = rEnumFont.elfStyle; @@ -558,7 +558,7 @@ static FontAttributes WinFont2DevFontAttributes( const ENUMLOGFONTEXW& rEnumFont if( *p < 0x0020 ) break; if( p < pEnd ) - aDFA.SetStyleName(o3tl::toU(pStyleName)); + aDFA.SetStyleName(OUString(o3tl::toU(pStyleName))); // heuristics for font quality // - opentypeTT > truetype @@ -962,7 +962,7 @@ void WinSalGraphics::GetFontMetric( ImplFontMetricDataRef& rxFontMetric, int nFa wchar_t aFaceName[LF_FACESIZE+60]; if( GetTextFaceW( getHDC(), SAL_N_ELEMENTS(aFaceName), aFaceName ) ) - rxFontMetric->SetFamilyName(o3tl::toU(aFaceName)); + rxFontMetric->SetFamilyName(OUString(o3tl::toU(aFaceName))); rxFontMetric->SetMinKashida(pFontInstance->GetKashidaWidth()); rxFontMetric->ImplCalcLineSpacing(pFontInstance.get()); |