summaryrefslogtreecommitdiff
path: root/vcl/win
diff options
context:
space:
mode:
authorPhilipp Lohmann [pl] <Philipp.Lohmann@Sun.COM>2009-12-11 13:49:58 +0100
committerPhilipp Lohmann [pl] <Philipp.Lohmann@Sun.COM>2009-12-11 13:49:58 +0100
commitaf24b66c7b07b21e0ef5268116d75e6c22b95c90 (patch)
tree4826d7b88f8368a29e17df24cd1cfabea56dc43b /vcl/win
parent0d1debd8e0179006d80f7f9ca443d21730f14dae (diff)
parentf8ada8f2a93659e27928f3b5244c813de2c3847b (diff)
merge with DEV300m67
Diffstat (limited to 'vcl/win')
-rw-r--r--vcl/win/source/gdi/salgdi3.cxx9
-rw-r--r--vcl/win/source/gdi/winlayout.cxx5
2 files changed, 6 insertions, 8 deletions
diff --git a/vcl/win/source/gdi/salgdi3.cxx b/vcl/win/source/gdi/salgdi3.cxx
index 73f4d8320acc..d82830a9022f 100644
--- a/vcl/win/source/gdi/salgdi3.cxx
+++ b/vcl/win/source/gdi/salgdi3.cxx
@@ -557,7 +557,7 @@ static ImplDevFontAttributes WinFont2DevFontAttributes( const ENUMLOGFONTEXA& rE
if( 0 != (rMetric.ntmFlags & (NTM_TT_OPENTYPE | NTM_PS_OPENTYPE))
|| 0 != (rMetric.tmPitchAndFamily & TMPF_TRUETYPE))
aDFA.mbSubsettable = true;
- else if( 0 != (rMetric.tmPitchAndFamily & NTM_TYPE1) ) // TODO: implement subsetting for type1 too
+ else if( 0 != (rMetric.ntmFlags & NTM_TYPE1) ) // TODO: implement subsetting for type1 too
aDFA.mbEmbeddable = true;
// heuristics for font quality
@@ -636,7 +636,7 @@ static ImplDevFontAttributes WinFont2DevFontAttributes( const ENUMLOGFONTEXW& rE
if( 0 != (rMetric.ntmFlags & (NTM_TT_OPENTYPE | NTM_PS_OPENTYPE))
|| 0 != (rMetric.tmPitchAndFamily & TMPF_TRUETYPE))
aDFA.mbSubsettable = true;
- else if( 0 != (rMetric.tmPitchAndFamily & NTM_TYPE1) ) // TODO: implement subsetting for type1 too
+ else if( 0 != (rMetric.ntmFlags & NTM_TYPE1) ) // TODO: implement subsetting for type1 too
aDFA.mbEmbeddable = true;
// heuristics for font quality
@@ -2162,7 +2162,7 @@ void WinSalGraphics::GetDevFontList( ImplDevFontList* pFontList )
::rtl::OUString aExecutableFile( aPath );
aPath = aPath.copy( 0, aPath.lastIndexOf('/') );
String aFontDirUrl = aPath.copy( 0, aPath.lastIndexOf('/') );
- aFontDirUrl += String( RTL_CONSTASCII_USTRINGPARAM("/share/fonts/truetype") );
+ aFontDirUrl += String( RTL_CONSTASCII_USTRINGPARAM("/Basis/share/fonts/truetype") );
// collect fonts in font path that could not be registered
osl::Directory aFontDir( aFontDirUrl );
@@ -2723,7 +2723,8 @@ const void* WinSalGraphics::GetEmbedFontData( const ImplFontData* pFont,
TEXTMETRICA aTm;
if( !::GetTextMetricsA( mhDC, &aTm ) )
*pDataLen = 0;
- rInfo.m_nFontType = FontSubsetInfo::ANY_TYPE1;
+ const bool bPFA = (*aRawFontData.get() < 0x80);
+ rInfo.m_nFontType = bPFA ? FontSubsetInfo::TYPE1_PFA : FontSubsetInfo::TYPE1_PFB;
WCHAR aFaceName[64];
int nFNLen = ::GetTextFaceW( mhDC, 64, aFaceName );
// #i59854# strip eventual null byte
diff --git a/vcl/win/source/gdi/winlayout.cxx b/vcl/win/source/gdi/winlayout.cxx
index 1b80bf578530..bf56b2a1082b 100644
--- a/vcl/win/source/gdi/winlayout.cxx
+++ b/vcl/win/source/gdi/winlayout.cxx
@@ -6,9 +6,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: winlayout.cxx,v $
- * $Revision: 1.113.6.9 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -1385,7 +1382,7 @@ bool UniscribeLayout::LayoutText( ImplLayoutArgs& rArgs )
mpScriptItems = NULL;
if( nRC != E_OUTOFMEMORY )
return false;
- if( nItemCapacity > (nSubStringEnd - mnSubStringMin) )
+ if( nItemCapacity > (nSubStringEnd - mnSubStringMin) + 16 )
return false;
}