summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2005-03-30 08:10:25 +0000
committerRüdiger Timm <rt@openoffice.org>2005-03-30 08:10:25 +0000
commit1189199942f8f836a7d0f1d6c447ae1336712b92 (patch)
tree263c2e47b9f72393aae1871eccee9994c50b2a4c /vcl
parent09f790a17112d4c009af0a912a5d973465ad011c (diff)
INTEGRATION: CWS vcl38 (1.14.104); FILE MERGED
2005/03/16 08:50:06 hdu 1.14.104.1: #i42190# allow symbol aliasing in winfont coverage
Diffstat (limited to 'vcl')
-rw-r--r--vcl/win/inc/salgdi.h20
1 files changed, 17 insertions, 3 deletions
diff --git a/vcl/win/inc/salgdi.h b/vcl/win/inc/salgdi.h
index 00d8dc080e98..a92ff88acd2d 100644
--- a/vcl/win/inc/salgdi.h
+++ b/vcl/win/inc/salgdi.h
@@ -2,9 +2,9 @@
*
* $RCSfile: salgdi.h,v $
*
- * $Revision: 1.14 $
+ * $Revision: 1.15 $
*
- * last change: $Author: hr $ $Date: 2004-11-26 16:15:28 $
+ * last change: $Author: rt $ $Date: 2005-03-30 09:10:25 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -109,7 +109,8 @@ public:
virtual ImplFontEntry* CreateFontInstance( ImplFontSelectData& ) const;
void UpdateFromHDC( HDC );
- bool HasChar( sal_Unicode c ) const { return mpUnicodeMap->HasChar(c); }
+ bool HasChar( sal_uInt32 cChar ) const;
+
WIN_BYTE GetCharSet() const { return meWinCharSet; }
WIN_BYTE GetPitchAndFamily() const { return mnPitchAndFamily; }
bool IsGlyphApiDisabled() const { return mbDisableGlyphApi; }
@@ -389,4 +390,17 @@ inline bool ImplCmpKernData( const KERNINGPAIR& a, const KERNINGPAIR& b )
return (a.wSecond < b.wSecond);
}
+// called extremely often from just one spot => inline
+inline bool ImplWinFontData::HasChar( sal_uInt32 cChar ) const
+{
+ if( mpUnicodeMap->HasChar( cChar ) )
+ return true;
+ // second chance to allow symbol aliasing
+ if( mbAliasSymbolsLow && ((cChar-0xF000) <= 0xFF) )
+ cChar -= 0xF000;
+ else if( mbAliasSymbolsHigh && (cChar <= 0xFF) )
+ cChar += 0xF000;
+ return mpUnicodeMap->HasChar( cChar );
+}
+
#endif // _SV_SALGDI_H