rpms/openoffice.org/devel openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch, 1.11, 1.12

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Mon Aug 14 08:21:29 UTC 2006


Author: caolanm

Update of /cvs/dist/rpms/openoffice.org/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv4779

Modified Files:
	openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch 
Log Message:
resync fontconfig hinting patch

openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch:
 psprint/inc/psprint/fontmanager.hxx        |   37 +++++-
 psprint/source/fontmanager/fontcache.cxx   |   13 --
 psprint/source/fontmanager/fontconfig.cxx  |   96 +++++++++++++---
 psprint/source/fontmanager/fontmanager.cxx |    6 -
 vcl/inc/impfont.hxx                        |   36 ++++++
 vcl/inc/outdev.hxx                         |    3 
 vcl/inc/outfont.hxx                        |    4 
 vcl/inc/salgdi.hxx                         |    2 
 vcl/inc/vclenum.hxx                        |   21 +++
 vcl/source/gdi/outdev3.cxx                 |    8 +
 vcl/source/glyphs/gcach_ftyp.cxx           |   80 ++++++++-----
 vcl/source/glyphs/gcach_ftyp.hxx           |    5 
 vcl/unx/inc/pspgraphics.h                  |    1 
 vcl/unx/inc/salgdi.h                       |    1 
 vcl/unx/source/gdi/pspgraphics.cxx         |   30 -----
 vcl/unx/source/gdi/salgdi3.cxx             |  168 +++++++++++++++++++++++++++++
 vcl/unx/source/gdi/xlfd_extd.cxx           |    3 
 vcl/win/inc/salgdi.h                       |    1 
 vcl/win/source/gdi/salgdi3.cxx             |    6 +
 19 files changed, 416 insertions(+), 105 deletions(-)

Index: openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch
===================================================================
RCS file: /cvs/dist/rpms/openoffice.org/devel/openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch	2 Jun 2006 21:04:58 -0000	1.11
+++ openoffice.org-2.0.2.ooo64508.vcl.honourfontconfighinting.patch	14 Aug 2006 08:21:22 -0000	1.12
@@ -149,7 +149,7 @@
 diff -ru vcl/source/glyphs/gcach_ftyp.cxx vcl/source/glyphs/gcach_ftyp.cxx
 --- openoffice.org.orig/vcl/source/glyphs/gcach_ftyp.cxx	2006-05-04 08:55:40.000000000 +0100
 +++ openoffice.org/vcl/source/glyphs/gcach_ftyp.cxx	2006-05-05 10:26:37.000000000 +0100
-@@ -45,6 +45,7 @@
+@@ -41,6 +41,7 @@
  #include <impfont.hxx>
  #include <bitmap.hxx>
  #include <bmpacc.hxx>
@@ -157,7 +157,7 @@
  
  #include <tools/poly.hxx>
  #include <basegfx/matrix/b2dhommatrix.hxx>
-@@ -595,9 +596,6 @@
+@@ -594,9 +595,6 @@
              aDFA.mbSubsettable= false;
              aDFA.mbEmbeddable = false;
  
@@ -167,32 +167,32 @@
              FT_Done_Face( aFaceFT );
              AddFontFile( aCFileName, nFaceNum, ++mnNextFontId, aDFA, NULL );
              ++nCount;
-@@ -686,6 +684,7 @@
- FreetypeServerFont::FreetypeServerFont( const ImplFontSelectData& rFSD, FtFontInfo* pFI )
+@@ -676,6 +674,7 @@
  :   ServerFont( rFSD ),
-     mnPrioEmbedded(nDefaultPrioEmbedded), mnPrioAntiAlias(nDefaultPrioAntiAlias),
+     mnPrioEmbedded(nDefaultPrioEmbedded),
+     mnPrioAntiAlias(nDefaultPrioAntiAlias),
 +    mnPrioAutoHint(nDefaultPrioAutoHint),
      mpFontInfo( pFI ),
      maFaceFT( NULL ),
      maSizeFT( NULL ),
-@@ -808,42 +807,67 @@
+@@ -805,42 +804,67 @@
  
      mbArtItalic = (rFSD.meItalic != ITALIC_NONE && pFI->GetFontAttributes().GetSlant() == ITALIC_NONE);
      mbArtBold = (rFSD.meWeight > WEIGHT_MEDIUM && pFI->GetFontAttributes().GetWeight() <= WEIGHT_MEDIUM);
 +    mbUseGamma = false;
 +    if (mbArtBold)
 +    {
-+        static const int TT_CODEPAGE_RANGE_874  = (1L << 16); // Thai
-+        static const int TT_CODEPAGE_RANGE_932  = (1L << 17); // JIS/Japan
-+        static const int TT_CODEPAGE_RANGE_936  = (1L << 18); // Chinese: Simplified
-+        static const int TT_CODEPAGE_RANGE_949  = (1L << 19); // Korean Wansung
-+        static const int TT_CODEPAGE_RANGE_950  = (1L << 20); // Chinese: Traditional
-+        static const int TT_CODEPAGE_RANGE_1361 = (1L << 21); // Korean Johab
-+        static const int TT_CODEPAGE_RANGES1_CJKT = 0x3F0000; // all of the above
-+        const TT_OS2* pOs2 = (const TT_OS2*)FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 );
-+        if ((pOs2) && (pOs2->ulCodePageRange1 & TT_CODEPAGE_RANGES1_CJKT )
-+	          && rFSD.mnHeight < 20)
-+	    mbUseGamma = true;
++	    //static const int TT_CODEPAGE_RANGE_874  = (1L << 16); // Thai
++	    //static const int TT_CODEPAGE_RANGE_932  = (1L << 17); // JIS/Japan
++	    //static const int TT_CODEPAGE_RANGE_936  = (1L << 18); // Chinese: Simplified
++	    //static const int TT_CODEPAGE_RANGE_949  = (1L << 19); // Korean Wansung
++	    //static const int TT_CODEPAGE_RANGE_950  = (1L << 20); // Chinese: Traditional
++	    //static const int TT_CODEPAGE_RANGE_1361 = (1L << 21); // Korean Johab
++	    static const int TT_CODEPAGE_RANGES1_CJKT = 0x3F0000; // all of the above
++	    const TT_OS2* pOs2 = (const TT_OS2*)FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 );
++	    if ((pOs2) && (pOs2->ulCodePageRange1 & TT_CODEPAGE_RANGES1_CJKT )
++		&& rFSD.mnHeight < 20)
++		mbUseGamma = true;
 +    }
 +
 +    ImplFontHints aHints;
@@ -203,23 +203,23 @@
 +    if (eHint == AUTOHINT_DONTKNOW)
 +        eHint = mbUseGamma ? AUTOHINT_TRUE : AUTOHINT_FALSE;
  
--    static const int TT_CODEPAGE_RANGE_874  = (1L << 16); // Thai
--    static const int TT_CODEPAGE_RANGE_932  = (1L << 17); // JIS/Japan
--    static const int TT_CODEPAGE_RANGE_936  = (1L << 18); // Chinese: Simplified
--    static const int TT_CODEPAGE_RANGE_949  = (1L << 19); // Korean Wansung
--    static const int TT_CODEPAGE_RANGE_950  = (1L << 20); // Chinese: Traditional
--    static const int TT_CODEPAGE_RANGE_1361 = (1L << 21); // Korean Johab
+-    //static const int TT_CODEPAGE_RANGE_874  = (1L << 16); // Thai
+-    //static const int TT_CODEPAGE_RANGE_932  = (1L << 17); // JIS/Japan
+-    //static const int TT_CODEPAGE_RANGE_936  = (1L << 18); // Chinese: Simplified
+-    //static const int TT_CODEPAGE_RANGE_949  = (1L << 19); // Korean Wansung
+-    //static const int TT_CODEPAGE_RANGE_950  = (1L << 20); // Chinese: Traditional
+-    //static const int TT_CODEPAGE_RANGE_1361 = (1L << 21); // Korean Johab
 -    static const int TT_CODEPAGE_RANGES1_CJKT = 0x3F0000; // all of the above
 -    const TT_OS2* pOs2 = (const TT_OS2*)FT_Get_Sfnt_Table( maFaceFT, ft_sfnt_os2 );
 -    if ((pOs2) && (pOs2->ulCodePageRange1 & TT_CODEPAGE_RANGES1_CJKT )
--	      && rFSD.mnHeight < 20)
--	mbUseGamma = true;
+-        && rFSD.mnHeight < 20)
+-        mbUseGamma = true;
 -    else
--	mbUseGamma = false;
+-        mbUseGamma = false;
 -
 -    if (mbUseGamma)
 +    if (eHint == AUTOHINT_TRUE)
- 	mnLoadFlags |= FT_LOAD_FORCE_AUTOHINT;
+         mnLoadFlags |= FT_LOAD_FORCE_AUTOHINT;
  
      if( (mnSin != 0) && (mnCos != 0) ) // hinting for 0/90/180/270 degrees only
          mnLoadFlags |= FT_LOAD_NO_HINTING;
@@ -228,12 +228,13 @@
 -    if (mpFontInfo->DontUseAntiAlias())
 -        mnPrioAntiAlias = 0;
 -    if (mpFontInfo->DontUseEmbeddedBitmaps())
+-        mnPrioEmbedded = 0;
 +    if (aHints.DontUseAntiAlias())
-+	mnPrioAntiAlias = 0;
++      mnPrioAntiAlias = 0;
 +    if (aHints.DontUseEmbeddedBitmaps())
-         mnPrioEmbedded = 0;
++      mnPrioEmbedded = 0;
 +    if (aHints.DontUseHinting())
-+    	mnPrioAutoHint = 0;
++      mnPrioAutoHint = 0;
  
  #if (FTVERSION >= 2005) || defined(TT_CONFIG_OPTION_BYTECODE_INTERPRETER)
 -    if( nDefaultPrioAutoHint <= 0 )
@@ -264,7 +265,7 @@
  #endif
  
      if( ((mnCos != 0) && (mnSin != 0)) || (mnPrioEmbedded <= 0) )
-@@ -1302,11 +1326,11 @@
+@@ -1297,11 +1321,11 @@
  #if (FTVERSION >= 2002)
      // for 0/90/180/270 degree fonts enable autohinting even if not advisable
      // non-hinted and non-antialiased bitmaps just look too ugly
@@ -278,7 +279,7 @@
          nLoadFlags |= FT_LOAD_NO_BITMAP;
  
      FT_Error rc = -1;
-@@ -1453,7 +1477,7 @@
+@@ -1446,7 +1470,7 @@
      // autohinting in FT<=2.0.4 makes antialiased glyphs look worse
      nLoadFlags |= FT_LOAD_NO_HINTING;
  #else




More information about the fedora-cvs-commits mailing list