diff options
author | Michael Stahl <mstahl@redhat.com> | 2015-11-25 17:22:54 +0100 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2015-11-25 20:34:19 +0100 |
commit | ba369045f605e76ad60d6828efcd6c316dea0da5 (patch) | |
tree | ff9587571cca75f9994139b9bbee39edefbb88c4 /vcl | |
parent | 4fee13c30eb7b67fd1c97466955742536265687c (diff) |
vcl: SalEnumFontsProcExA is unused since 2010
Change-Id: Id1b1de27752a6b8a74ea3521b53c38f032bfa24b
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/win/source/gdi/salgdi3.cxx | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/vcl/win/source/gdi/salgdi3.cxx b/vcl/win/source/gdi/salgdi3.cxx index 94127996dba5..98fde754317d 100644 --- a/vcl/win/source/gdi/salgdi3.cxx +++ b/vcl/win/source/gdi/salgdi3.cxx @@ -915,22 +915,6 @@ static ImplDevFontAttributes WinFont2DevFontAttributes( const ENUMLOGFONTEXW& rE return aDFA; } -static ImplWinFontData* ImplLogMetricToDevFontDataA( const ENUMLOGFONTEXA* pLogFont, - const NEWTEXTMETRICA* pMetric, - DWORD nFontType ) -{ - int nHeight = 0; - if ( nFontType & RASTER_FONTTYPE ) - nHeight = pMetric->tmHeight - pMetric->tmInternalLeading; - - ImplWinFontData* pData = new ImplWinFontData( - WinFont2DevFontAttributes(*pLogFont, *pMetric, nFontType), - nHeight, - pLogFont->elfLogFont.lfCharSet, - pMetric->tmPitchAndFamily ); - - return pData; -} static ImplWinFontData* ImplLogMetricToDevFontDataW( const ENUMLOGFONTEXW* pLogFont, const NEWTEXTMETRICW* pMetric, @@ -1662,60 +1646,6 @@ bool WinSalGraphics::GetFontCapabilities(vcl::FontCapabilities &rFontCapabilitie return mpWinFontData[0]->GetFontCapabilities(rFontCapabilities); } -int CALLBACK SalEnumFontsProcExA( const ENUMLOGFONTEXA* pLogFont, - const NEWTEXTMETRICEXA* pMetric, - DWORD nFontType, LPARAM lParam ) -{ - ImplEnumInfo* pInfo = (ImplEnumInfo*)(void*)lParam; - if ( !pInfo->mpName ) - { - // Ignore vertical fonts - if ( pLogFont->elfLogFont.lfFaceName[0] != '@' ) - { - if ( !pInfo->mbImplSalCourierNew ) - pInfo->mbImplSalCourierNew = stricmp( pLogFont->elfLogFont.lfFaceName, "Courier New" ) == 0; - if ( !pInfo->mbImplSalCourierScalable ) - pInfo->mbCourier = stricmp( pLogFont->elfLogFont.lfFaceName, "Courier" ) == 0; - else - pInfo->mbCourier = FALSE; - OUString aName( ImplSalGetUniString( pLogFont->elfLogFont.lfFaceName ) ); - pInfo->mpName = &aName; - strncpy( pInfo->mpLogFontA->lfFaceName, pLogFont->elfLogFont.lfFaceName, LF_FACESIZE ); - pInfo->mpLogFontA->lfCharSet = pLogFont->elfLogFont.lfCharSet; - EnumFontFamiliesExA( pInfo->mhDC, pInfo->mpLogFontA, (FONTENUMPROCA)SalEnumFontsProcExA, - (LPARAM)(void*)pInfo, 0 ); - pInfo->mpLogFontA->lfFaceName[0] = '\0'; - pInfo->mpLogFontA->lfCharSet = DEFAULT_CHARSET; - pInfo->mpName = NULL; - pInfo->mbCourier = FALSE; - } - } - else - { - // ignore non-scalable non-device font on printer - if( pInfo->mbPrinter ) - if( (nFontType & RASTER_FONTTYPE) && !(nFontType & DEVICE_FONTTYPE) ) - return 1; - - ImplWinFontData* pData = ImplLogMetricToDevFontDataA( pLogFont, &(pMetric->ntmTm), nFontType ); - pData->SetFontId( sal_IntPtr( pInfo->mnFontCount++ ) ); - - // prefer the system character set, so that we get as much as - // possible important characters. In the other case we could only - // display a limited set of characters (#87309#) - if ( pInfo->mnPreferredCharSet == pLogFont->elfLogFont.lfCharSet ) - pData->mnQuality += 100; - - // knowing Courier to be scalable is nice - if( pInfo->mbCourier ) - pInfo->mbImplSalCourierScalable |= pData->IsScalable(); - - pInfo->mpList->Add( pData ); - } - - return 1; -} - int CALLBACK SalEnumFontsProcExW( const ENUMLOGFONTEXW* pLogFont, const NEWTEXTMETRICEXW* pMetric, DWORD nFontType, LPARAM lParam ) |